mpx / lua-cjson

Lua CJSON is a fast JSON encoding/parsing module for Lua
https://kyne.au/~mark/software/lua-cjson.php
MIT License
933 stars 478 forks source link

decode null to cjson.null #88

Open xxy7800 opened 4 months ago

xxy7800 commented 4 months ago

Hello, I have a question. When I use decode to handle a string like "expirePay":{"key":"","value":null,"descr":""}, the value is converted to cjson.null instead of Lua's nil. cjson.null is treated as userdata in my Lua script and I can't process it. How should I handle this? Thank you.