Capture fs locally before setting _ENV=nil in json.lua
This commit is contained in:
@@ -39,8 +39,8 @@ if register_global_module_table then
|
|||||||
_G[global_module_name] = json
|
_G[global_module_name] = json
|
||||||
end
|
end
|
||||||
|
|
||||||
-- this was incompatible because we use fs later
|
local fs = fs
|
||||||
--local _ENV = nil -- blocking globals in Lua 5.2
|
local _ENV = nil -- blocking globals in Lua 5.2
|
||||||
|
|
||||||
pcall (function()
|
pcall (function()
|
||||||
-- Enable access to blocked metatables.
|
-- Enable access to blocked metatables.
|
||||||
|
|||||||
Reference in New Issue
Block a user