lua-cjson
lua-cjson copied to clipboard
encode and decode invalid Json, throws error
Hi all,
I just want to understand why encode invalid JSON works well without exception but decode breaks with an error.
My use case is to encode data on Redis for caching an HTTP request, and when another request matches the criteria, the value on Redis, when decoded, throws an error saying that it is not possible to decode. I´m still trying to understand what is the upstream answering with invalid json, but I need now to not store on redis when json is not valid