diff options
| author | django-bot <ops@djangoproject.com> | 2025-07-22 20:41:41 -0700 |
|---|---|---|
| committer | nessita <124304+nessita@users.noreply.github.com> | 2025-07-23 20:17:55 -0300 |
| commit | 69a93a88edb56ba47f624dac7a21aacc47ea474f (patch) | |
| tree | f57507a4435d032493cae40e06ecb254790b67b2 /django/db/models/query_utils.py | |
| parent | 55b0cc21310b76ce4018dd793ba50556eaf0af06 (diff) | |
Refs #36500 -- Rewrapped long docstrings and block comments via a script.
Rewrapped long docstrings and block comments to 79 characters + newline
using script from https://github.com/medmunds/autofix-w505.
Diffstat (limited to 'django/db/models/query_utils.py')
| -rw-r--r-- | django/db/models/query_utils.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/django/db/models/query_utils.py b/django/db/models/query_utils.py index 3e644a3c26..5da3d81672 100644 --- a/django/db/models/query_utils.py +++ b/django/db/models/query_utils.py @@ -302,8 +302,9 @@ class RegisterLookupMixin: @staticmethod def merge_dicts(dicts): """ - Merge dicts in reverse to preference the order of the original list. e.g., - merge_dicts([a, b]) will preference the keys in 'a' over those in 'b'. + Merge dicts in reverse to preference the order of the original list. + e.g., merge_dicts([a, b]) will preference the keys in 'a' over those in + 'b'. """ merged = {} for d in reversed(dicts): @@ -435,8 +436,8 @@ def check_rel_lookup_compatibility(model, target_opts, field): # Restaurant.objects.filter(pk__in=Restaurant.objects.all()). # If we didn't have the primary key check, then pk__in (== place__in) would # give Place's opts as the target opts, but Restaurant isn't compatible - # with that. This logic applies only to primary keys, as when doing __in=qs, - # we are going to turn this into __in=qs.values('pk') later on. + # with that. This logic applies only to primary keys, as when doing + # __in=qs, we are going to turn this into __in=qs.values('pk') later on. return check(target_opts) or ( getattr(field, "primary_key", False) and check(field.model._meta) ) |
