jackson-module-kotlin
jackson-module-kotlin copied to clipboard
Take into account Java Optional when calculating the property's required marker
class Data(val id: String, val email: Optional<String>)
email field is marked as required, but if we not pass data to it, it works correctly, it is initialized with Optional.empty.
Please mark Optional as non required.
@raderio jackson deserializes null or lack of the value as Optional.empty because it logically means absent of value. What's wrong with that?