fix(config-core): hopefully prevent config parsing issue with nulls
This commit is contained in:
parent
45cbc38d68
commit
580a74fee8
|
@ -135,8 +135,10 @@ public class DslEntryInfo<T> implements EntryInfo<T> {
|
|||
} else if (type.isString()) {
|
||||
if (next == JsonToken.STRING || next == JsonToken.NUMBER) setUnchecked(reader.nextString());
|
||||
else if (next == JsonToken.BOOLEAN) setUnchecked(Boolean.toString(reader.nextBoolean()));
|
||||
else if (next == JsonToken.NULL) setUnchecked(null);
|
||||
else LibJf.LOGGER.error("Unexpected value for " + name + ": expected string but got " + next);
|
||||
else if (next == JsonToken.NULL) {
|
||||
reader.nextNull();
|
||||
setUnchecked(null);
|
||||
} else LibJf.LOGGER.error("Unexpected value for " + name + ": expected string but got " + next);
|
||||
} else if (type.isInt()) {
|
||||
if (next == JsonToken.NUMBER) setUnchecked(reader.nextInt());
|
||||
else LibJf.LOGGER.error("Unexpected value for " + name + ": expected number but got " + next);
|
||||
|
|
Loading…
Reference in New Issue