data optional

This commit is contained in:
j 2011-01-14 16:21:50 +05:30
parent 7d0058787a
commit b3aa9dfd7d

View file

@ -75,7 +75,7 @@ class ApiActions(dict):
}
}
'''
data = json.loads(request.POST['data'])
data = json.loads(request.POST.get('data', '{}'))
docs = data.get('docs', False)
_actions = self.keys()
_actions.sort()