aboutsummaryrefslogtreecommitdiff
path: root/src/web/views/api
diff options
context:
space:
mode:
Diffstat (limited to 'src/web/views/api')
-rw-r--r--src/web/views/api/v2/common.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/web/views/api/v2/common.py b/src/web/views/api/v2/common.py
index 64c76a7e..0d5d8090 100644
--- a/src/web/views/api/v2/common.py
+++ b/src/web/views/api/v2/common.py
@@ -75,7 +75,10 @@ class PyAggAbstractResource(Resource):
the args to parse, if None, self.attrs will be used
"""
try:
- in_values = req.json if req else (request.args or {})
+ if req:
+ in_values = req.json
+ else:
+ in_values = request.args or request.json or {}
if not in_values and allow_empty:
return {}
except BadRequest:
bgstack15