Description

Troubleshooting

Reproduction

Hello,
i have an issue with the JSON module .

i have JSON response from a HTTP request to process in my script:

{"status":"SUCCESS"}

i use the command HTTP_query:

http_query("http://xxxxx", "$var(result)");

then i try to parse my result:

json_get_field("$var(result)", "status", "$var(status)");

But when i log my result:
xlog("L_INFO", "$var(status)");

i have a wrong output:

INFO: <script>: "SUCCESS"

double quote is embedded in the string variable which is wrong because this not part of my json value.

Is there any way to fix this behaviour or having a new function in order to retrieve the right value of my json field?

Thank you for your help.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.