Skip to content

Conversation

dondonz
Copy link
Member

@dondonz dondonz commented Aug 27, 2022

Inside graphql-java, a NullValue is always coerced into null, see ValuesResolverConversion.literalToInternalValueImpl. This happens before a scalar's parseLiteral method is called.

In other words, a scalar's parseLiteral method never needs to consider NullValue. This PR removes the redundant lines from ObjectScalar.

See further discussion: graphql-java/graphql-java#2904

@dondonz dondonz merged commit 5b55a08 into graphql-java:master Aug 29, 2022
@dondonz dondonz deleted the fix-up-ObjectScalar branch August 29, 2022 00:31
@dondonz dondonz added this to the 19.0 milestone Sep 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants