This commit is contained in:
Jakub Roztocil 2016-07-01 19:00:06 +02:00
parent 963b2746f5
commit 65081b2f12

View File

@ -15,8 +15,8 @@ class JSONFormatter(FormatterPlugin):
'javascript',
'text',
]
if (any(token in mime for token in maybe_json) or
self.kwargs['explicit_json']):
if (self.kwargs['explicit_json'] or
any(token in mime for token in maybe_json)):
try:
obj = json.loads(body)
except ValueError: