diff options
| author | Ramiro Morales <cramm0@gmail.com> | 2018-08-08 22:25:18 -0300 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2018-08-10 12:17:26 -0400 |
| commit | b5c7cb4d3306a7b4e8f87bcf365ff30ae53018ed (patch) | |
| tree | 2c58f65b31b02ebb5d3d3402404e3ba7d6202600 /django/db/models/base.py | |
| parent | 64e1a271f50d921a54388539b6ff7102a31c3d29 (diff) | |
Fixed #29653 -- Fixed missing related_query_name reverse accessor if GenericRelation is declared on an abstract base model.
Regression in 4ab027b94409e6415b774797bf9d3593da9d9ea8.
Thanks Lauri Kainulainen for the report.
Diffstat (limited to 'django/db/models/base.py')
| -rw-r--r-- | django/db/models/base.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/django/db/models/base.py b/django/db/models/base.py index d92fcb893a..3c2147ba78 100644 --- a/django/db/models/base.py +++ b/django/db/models/base.py @@ -280,7 +280,8 @@ class ModelBase(type): ) else: field = copy.deepcopy(field) - field.mti_inherited = True + if not base._meta.abstract: + field.mti_inherited = True new_class.add_to_class(field.name, field) # Copy indexes so that index names are unique when models extend an |
