Closed frsyuki closed 8 years ago
Interesting. Thank you for reporting this, will try to fix it.
Ok. This is due to a lesser-known aspect of deserialization of JSON Objects; parser may be positioned over first content token, and this in turn may actually be END_OBJECT
. Fixed ObjectNode
deserializer to handle that correctly.
I found that deserializing from an empty object (
{}
) to ObjectNode field in a class field fails.Here is the minimum code to reproduce:
Result is:
If the object is not empty (e.g.
{"k":"v"}
), it works:Environment:
Java(TM) SE Runtime Environment (build 1.8.0_20-b26)
)