You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
raise"Implement `def self.legacy_invalid_empty_selections_on_union_with_type(query, type)` or `def self.legacy_invalid_empty_selections_on_union(query)` to handle this scenario"
1741
+
end
1742
+
1727
1743
# This method is called during validation when a previously-allowed, but non-spec
1728
1744
# query is encountered where a union field has no child selections on it.
1729
1745
#
1730
1746
# You should implement this method to log the violation so that you can contact clients
1731
1747
# and notify them about changing their queries. Then return a suitable value to
1732
1748
# tell GraphQL-Ruby how to continue.
1733
1749
# @param query [GraphQL::Query]
1750
+
# @param type1 [Module] A GraphQL type definition
1734
1751
# @return [:return_validation_error] Let GraphQL-Ruby return the (new) normal validation error for this query
1735
1752
# @return [String] A validation error to return for this query
1736
1753
# @return [nil] Don't send the client an error, continue the legacy behavior (allow this query to execute)
raiseGraphQL::InvariantError,"Unexpected return value from legacy_invalid_empty_selections_on_union, must be `:return_validation_error`, String, or nil (got: #{legacy_invalid_empty_selection_result.inspect})"
64
+
raiseGraphQL::InvariantError,"Unexpected return value from legacy_invalid_empty_selections_on_union_with_type, must be `:return_validation_error`, String, or nil (got: #{legacy_invalid_empty_selection_result.inspect})"
0 commit comments