forked from 0x2620/pandora
cleanup
This commit is contained in:
parent
7ae02d5678
commit
2e246dd06e
1 changed files with 1 additions and 3 deletions
|
@ -703,8 +703,6 @@ def lookup(request, data):
|
||||||
if 'id' in data:
|
if 'id' in data:
|
||||||
i = models.Item.objects.get(public_id=data['id'])
|
i = models.Item.objects.get(public_id=data['id'])
|
||||||
elif not filter(None, [d not in ('title', 'year', 'director') for d in data.keys()]):
|
elif not filter(None, [d not in ('title', 'year', 'director') for d in data.keys()]):
|
||||||
key = data.keys()[0]
|
|
||||||
value = data[key]
|
|
||||||
qs = models.Item.objects.find({'query': {
|
qs = models.Item.objects.find({'query': {
|
||||||
'conditions': [
|
'conditions': [
|
||||||
{'key': key, 'value': data[key], 'operator': '=='} for key in data
|
{'key': key, 'value': data[key], 'operator': '=='} for key in data
|
||||||
|
|
Loading…
Reference in a new issue