Some strings containing invalid JSON raises a NullPointerException
Opened this issue · 1 comments
tom-beck commented
Calling new LazyObject("{\"key\":2]")
will raise a LazyException.
Calling new LazyObject("{\"key\":2}\"")
will raise a NullPointer exception.
It would be great if all parsing issues raised a LazyException.
The stacktrace:
java.lang.NullPointerException
at me.doubledutch.lazyjson.LazyParser.tokenize(LazyParser.java:263)
at me.doubledutch.lazyjson.LazyObject.<init>(LazyObject.java:23)
kasperjj commented
Yeah, that absolutely should be raising a LazyException! Thanks for reporting this!