Fixed table.json

This commit is contained in:
Cooldude2606
2018-12-31 17:23:08 +00:00
parent c0d689f9ce
commit 9a09649635
2 changed files with 15 additions and 6 deletions

View File

@@ -259,7 +259,7 @@ function table.json(lua_table)
for key,value in ipairs(lua_table) do
done[key] = true
if type(value) == 'table' then table.insert(result,table.json(value,true))
elseif not vlaue then table.insert(result,'null')
elseif not value then table.insert(result,'null')
else table.insert(result,table.val_to_str(value))
end
end