fix(serialize-xml): fix values in objects not permitted
This commit is contained in:
parent
fcc3d97150
commit
0b6783c9bd
@ -199,6 +199,9 @@ public class XmlWriter extends SerializeWriter<IOException, XmlWriter> implement
|
||||
private void beforeValue() throws IOException {
|
||||
switch (peek()) {
|
||||
case DOCUMENT, ARRAY, OBJECT_VALUE_WRAPPER -> {}
|
||||
case OBJECT -> {
|
||||
if (deferredName == null) throw new IllegalStateException("Name not set.");
|
||||
}
|
||||
default -> throw new IllegalStateException("Nesting problem.");
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user