mirror of
https://github.com/jazzband/django-eav2.git
synced 2026-05-23 22:55:54 +00:00
fix(lint): fix en dash lint errors
This commit is contained in:
parent
9c04f3e300
commit
1559ff79fb
1 changed files with 2 additions and 2 deletions
|
|
@ -28,10 +28,10 @@ Q-expressions need to be rewritten for two reasons:
|
|||
The correct way to express "entities where attr A = x AND attr B ≠ y"
|
||||
is to chain ``.exclude()`` instead::
|
||||
|
||||
# Wrong – row-level negation, may return unexpected results
|
||||
# Wrong - row-level negation, may return unexpected results
|
||||
MyModel.objects.filter(Q(eav__a=x) & ~Q(eav__b=y))
|
||||
|
||||
# Correct – entity-level negation
|
||||
# Correct - entity-level negation
|
||||
MyModel.objects.filter(eav__a=x).exclude(eav__b=y)
|
||||
"""
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue