Merge pull request #261 from yoloseem/parsed_json
Cache request.json even when it's empty.
This commit is contained in:
commit
b0bf989056
|
@ -64,7 +64,7 @@ class Request(dict):
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def json(self):
|
def json(self):
|
||||||
if not self.parsed_json:
|
if self.parsed_json is None:
|
||||||
try:
|
try:
|
||||||
self.parsed_json = json_loads(self.body)
|
self.parsed_json = json_loads(self.body)
|
||||||
except Exception:
|
except Exception:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user