mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 04:30:44 +01:00
Make JSON.stringify encode numbers properly
JSON doesn't allow scientific/exponential notation... Fixes #14098
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
/datum/jsonHelper/proc/WriteValue(list/json, value)
|
||||
. = json
|
||||
if(isnum(value))
|
||||
json += value // Consider num2text(value, 20) for maximum accuracy.
|
||||
json += num2text(value, 20)
|
||||
else if(isnull(value))
|
||||
json += "null"
|
||||
else if(istext(value))
|
||||
|
||||
Reference in New Issue
Block a user