diff options
| author | viliam mihalik <viliam.mihalik@smartbase.sk> | 2025-06-05 23:53:01 +0200 |
|---|---|---|
| committer | Sarah Boyce <42296566+sarahboyce@users.noreply.github.com> | 2025-06-12 08:36:54 +0200 |
| commit | bd65e82831304ede92af6e9f0807daa3a874efc0 (patch) | |
| tree | b99772eb02ba33449247a97d7d22a1f92b2f74e4 /django | |
| parent | 95a5c9b794fe2ad83344c7ac3ca6e940eb7e0949 (diff) | |
Fixed #36442 -- Cloned FilteredRelation before rename_prefix_from_q.
Diffstat (limited to 'django')
| -rw-r--r-- | django/db/models/sql/query.py | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/django/db/models/sql/query.py b/django/db/models/sql/query.py index 92a09c5840..187349a460 100644 --- a/django/db/models/sql/query.py +++ b/django/db/models/sql/query.py @@ -1723,6 +1723,7 @@ class Query(BaseExpression): "relations deeper than the relation_name (got %r for " "%r)." % (lookup, filtered_relation.relation_name) ) + filtered_relation = filtered_relation.clone() filtered_relation.condition = rename_prefix_from_q( filtered_relation.relation_name, alias, |
