mirror of
https://github.com/django/django.git
synced 2025-10-28 08:06:09 +00:00
Fixed #34458 -- Fixed QuerySet.defer() crash on attribute names.
Thanks Andrew Cordery for the report.
Regression in b3db6c8dcb.
This commit is contained in:
committed by
Mariusz Felisiak
parent
ff9ceed32b
commit
87c63bd8df
@@ -702,7 +702,8 @@ class Query(BaseExpression):
|
||||
# by recursively calling this function.
|
||||
for field in opts.concrete_fields:
|
||||
field_mask = mask.pop(field.name, None)
|
||||
if field_mask is None:
|
||||
field_att_mask = mask.pop(field.attname, None)
|
||||
if field_mask is None and field_att_mask is None:
|
||||
select_mask.setdefault(field, {})
|
||||
elif field_mask:
|
||||
if not field.is_relation:
|
||||
|
||||
Reference in New Issue
Block a user