I'm getting an "Argument has invalid value" error message when using FilterInputObjectFields
#5282
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Here's a sample schema I'm playing with:
Here's the transformation that removes the
stars
input argument:The filter works as expected, I see the
stars
field being removed from theReviewInput
argument:But when I submit the mutation I'm getting the following error:
Am I missing something? Is there something else left to do after applying the
FilterInputObjectFields
transformation?EDIT:
If I filter-out the
commentary
field:Then everything works as expected. I'm getting the success message:
The only difference between these two fields is that one is an optional field and the other is a required field. This makes me wonder if filtering out required fields needs some special treatment. I was expecting
FilterInputObjectFields
to take care of everything.EDIT:
I've just realised that everything works as expected. If I wrap/stich a schema than the original schema remains unchanged. Reqests are delegated to the original schema where required fields still remain required :)
Beta Was this translation helpful? Give feedback.
All reactions