Replies: 1 comment
-
I just reviewed and approved the PR. This suggested change in behavior makes sense to me. 🤞 it doesn't break anyone. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I opened an issue and a PR on the matter that input types codegened in Kotlin uses the same nullability detection as output types, which means that the
kotlinAllFieldsOptional
property makes all input fields in the generated types nullable, ignoring the type information in the schema.The
kotlinAllFieldsOptional
is useful for output types in order to decide whether return values should be inlined or resolved specifically using a custom@DgsData
method. But this, in my mind, is not true for input types. There is no need for all fields to be nullable in input types. And currently usingkotlinAllFieldsOptional
means we lose that type information, and have to force unwrap a bunch everywhere in our code.What do you think of changing this behaviour, as suggested in the PR/issue?
Beta Was this translation helpful? Give feedback.
All reactions