Commit 0bd74a2a2f5283abc2620c64a2a681663af55498

Authored by David RENÉ
1 parent 86b31c14

[!] fix empty string in JSON object in non json lib extension call.

Showing 1 changed file with 1 additions and 1 deletions   Show diff stats
web/json.anubis
... ... @@ -270,7 +270,7 @@ public define Printable_tree
270 270 json_array(values) then [ "[", format_json_array(values), "]" . [] ],
271 271 json_int(i) then int_pt(i, []),
272 272 json_float(f, p) then str_pt(float_to_string(f, p), []),
273   - json_string(s) then str_pt(format_json_esc(s), []),
  273 + json_string(s) then if s ="" then str_pt("\"\"", []) else str_pt(format_json_esc(s), []),
274 274 json_bool(b) then str_pt(if b then "true" else "false", []),
275 275 json_null then str_pt("null", [])
276 276 }.
... ...