Kotlin boolean with 'is' prefix -> field name is wrong
klaus7 opened this issue · comments
Klaus Pfeiffer commented
If you declare a boolean property with an 'is' prefix like:
var isPrimaryUser: Boolean? = false
... this is generated:
primaryUser: boolean | null
Which is not correct and won't work, because the objects from the backend are serialized in an object like
{
isPrimaryUser: false
}
Klaus Pfeiffer commented
Found a workaround:
@get:JsonProperty("isPrimaryUser")
var isPrimaryUser: Boolean? = false