mirror of
https://github.com/jointakahe/takahe.git
synced 2024-11-29 02:31:00 +00:00
parent
029e51c8fe
commit
b523d34c53
1 changed files with 1 additions and 1 deletions
|
@ -11,7 +11,7 @@ class FormOrJsonParser(Parser):
|
|||
|
||||
def parse_body(self, request):
|
||||
# Did they submit JSON?
|
||||
if request.content_type == "application/json":
|
||||
if request.content_type == "application/json" and request.body.strip():
|
||||
return json.loads(request.body)
|
||||
# Fall back to form data
|
||||
value = {}
|
||||
|
|
Loading…
Reference in a new issue