forked from 0x2620/pandora
make keys optional in get request
This commit is contained in:
parent
c06f94fb24
commit
425c7a874a
1 changed files with 1 additions and 0 deletions
|
@ -389,6 +389,7 @@ def get(request):
|
|||
'''
|
||||
response = json_response({})
|
||||
data = json.loads(request.POST['data'])
|
||||
data['keys'] = data.get('keys', [])
|
||||
item = get_object_or_404_json(models.Item, itemId=data['id'])
|
||||
if item.access(request.user):
|
||||
info = item.get_json(data['keys'])
|
||||
|
|
Loading…
Reference in a new issue