Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 9cbe59b

Browse filesBrowse files
committed
Fixed assertion errors
1 parent 330a59f commit 9cbe59b
Copy full SHA for 9cbe59b

File tree

1 file changed

+5
-1
lines changed
Filter options

1 file changed

+5
-1
lines changed

‎flask_graphql/graphqlview.py

Copy file name to clipboardExpand all lines: flask_graphql/graphqlview.py
+5-1Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,11 @@ def dispatch_request(self):
9595
only_allow_query = request_method == 'get'
9696

9797
if not is_batch:
98-
assert isinstance(data, dict), "GraphQL params should be a dict. Received {}.".format(data)
98+
if not isinstance(data, dict):
99+
raise HttpQueryError(
100+
400,
101+
'GraphQL params should be a dict. Received {}.'.format(data)
102+
)
99103
data = dict(data, **request.args.to_dict())
100104
data = [data]
101105
elif not self.batch:

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.