From fb4c730708a4140f05d2161c27e6c58bb0f72a9b Mon Sep 17 00:00:00 2001 From: raymoo Date: Sat, 8 Apr 2017 01:42:59 -0700 Subject: Document that write_json will error on unserializable types. (#5539) Previously it was erroneously documented that it would save them as null. --- doc/client_lua_api.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc/client_lua_api.md') diff --git a/doc/client_lua_api.md b/doc/client_lua_api.md index d68f90dec..bee53636c 100644 --- a/doc/client_lua_api.md +++ b/doc/client_lua_api.md @@ -712,7 +712,7 @@ Call these functions only at load time! * `minetest.write_json(data[, styled])`: returns a string or `nil` and an error message * Convert a Lua table into a JSON string * styled: Outputs in a human-readable format if this is set, defaults to false - * Unserializable things like functions and userdata are saved as null. + * Unserializable things like functions and userdata will cause an error. * **Warning**: JSON is more strict than the Lua table format. 1. You can only use strings and positive integers of at least one as keys. 2. You can not mix string and integer keys. -- cgit v1.2.3