Skip to content

Commit

Permalink
Remove redundant has_request_context check
Browse files Browse the repository at this point in the history
  • Loading branch information
robdiciuccio committed Aug 31, 2021
1 parent cb2fae8 commit 35e50fe
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions superset/views/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,11 +135,7 @@ def get_form_data( # pylint: disable=too-many-locals
# chart data API requests are JSON
request_json_data = (
request.json["queries"][0]
if (
has_request_context() # type: ignore
and request.is_json
and "queries" in request.json
)
if request.is_json and "queries" in request.json
else None
)

Expand Down

0 comments on commit 35e50fe

Please sign in to comment.