1
0
mirror of https://github.com/django/django.git synced 2025-10-24 06:06:09 +00:00

Fixed #28543 -- Prevented ManyToManyField.value_from_object() from being lazy.

Previously, it was a QuerySet which could reevaluate to a new value if the
model's data changes. This is inconsistent with other Field.value_from_object()
methods.

This allows reverting the fix in the admin for refs #27998.
This commit is contained in:
Tim Graham
2017-08-31 09:34:44 -04:00
committed by GitHub
parent ec6481246a
commit e5bd585c6e
6 changed files with 41 additions and 18 deletions

View File

@@ -360,6 +360,10 @@ class AllFieldsModel(models.Model):
gr = GenericRelation(DataModel)
class ManyToMany(models.Model):
m2m = models.ManyToManyField('self')
###############################################################################