fastjson2
fastjson2 copied to clipboard
2413 fix
What this PR does / why we need it?
JSONObject.from(Object obj) Currently we have only method which expects type Object and getting class cast exception when we pass string
Summary of your change
Overloaded method for String argument and invoking JSON.parseObject(text) to return JSONObject
Please indicate you've done the following:
- [ ] Made sure tests are passing and test coverage is added if needed.
- [ ] Made sure commit message follow the rule of Conventional Commits specification.
- [ ] Considered the docs impact and opened a new docs issue or PR with docs changes if needed.
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.