diff options
author | Tomás Touceda <chiiph@leap.se> | 2013-07-04 18:27:02 -0300 |
---|---|---|
committer | Tomás Touceda <chiiph@leap.se> | 2013-07-05 16:12:15 -0300 |
commit | 4f74133db5595b556b84e173a2e754f469eeb2c2 (patch) | |
tree | f3da10ce2e9c9d2b8953f13ade26c659144d383f /src | |
parent | bd25a726021192f13df509fb8e25ccacd50f43a7 (diff) |
Check if request content is None before doing anything
Diffstat (limited to 'src')
-rw-r--r-- | src/leap/util/request_helpers.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/leap/util/request_helpers.py b/src/leap/util/request_helpers.py index e06dabb8..350abfbd 100644 --- a/src/leap/util/request_helpers.py +++ b/src/leap/util/request_helpers.py @@ -41,7 +41,7 @@ def get_content(request): contents = "" mtime = None - if request.json: + if request.content and request.json: if callable(request.json): contents = json.dumps(request.json()) else: |