Merge remote-tracking branch 'origin/pr/445'
This commit is contained in:
commit
8a3171308a
1 changed files with 2 additions and 2 deletions
|
|
@ -43,11 +43,11 @@ def query(_doc_cls=None, _field_operation=False, **query):
|
|||
parts = [part for part in parts if not part.isdigit()]
|
||||
# Check for an operator and transform to mongo-style if there is
|
||||
op = None
|
||||
if parts[-1] in MATCH_OPERATORS:
|
||||
if len(parts) > 1 and parts[-1] in MATCH_OPERATORS:
|
||||
op = parts.pop()
|
||||
|
||||
negate = False
|
||||
if parts[-1] == 'not':
|
||||
if len(parts) > 1 and parts[-1] == 'not':
|
||||
parts.pop()
|
||||
negate = True
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue