Allow 'query' to be omitted from find*() (fixes #2883)
I hit this in findDocuments() so thought I'd fix them all.
This commit is contained in:
parent
b121b58a86
commit
47d8d67c3d
7 changed files with 22 additions and 12 deletions
|
|
@ -80,7 +80,10 @@ def findLists(request, data):
|
|||
return x['key'] == 'status' and \
|
||||
x['value'] == 'featured' and \
|
||||
x['operator'] in ('=', '==')
|
||||
is_featured = len(filter(is_featured_condition, data['query'].get('conditions', []))) > 0
|
||||
is_featured = any(
|
||||
is_featured_condition(x)
|
||||
for x in data.get('query', {}).get('conditions', [])
|
||||
)
|
||||
|
||||
if is_section_request:
|
||||
qs = query['qs']
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue