We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 03cd524 commit 7fe0d47Copy full SHA for 7fe0d47
graphql/validation/rules/variables_in_allowed_position.py
@@ -76,8 +76,9 @@ def allowed_variable_usage(
76
it is located.
77
"""
78
if is_non_null_type(location_type) and not is_non_null_type(var_type):
79
- has_non_null_variable_default_value = var_default_value and not isinstance(
80
- var_default_value, NullValueNode
+ has_non_null_variable_default_value = (
+ var_default_value is not None
81
+ and not isinstance(var_default_value, NullValueNode)
82
)
83
has_location_default_value = location_default_value is not INVALID
84
if not has_non_null_variable_default_value and not has_location_default_value:
0 commit comments