graphql-java-tools
graphql-java-tools copied to clipboard
Null boolean parameter is coerced to false when Java type is primitive boolean
mutation {
createCat(enabled: Boolean): Cat!
}
public Cat createCat(boolean enabled) {
...
}
when executing:
mutation {
createCat {
id
}
}
The value of enabled gets coerced to false. Instead, this should throw and require a nullable Boolean type to be used instead. Preferably it should throw at startup.