mirror of
https://github.com/MightyPirates/OpenComputers.git
synced 2025-08-03 11:07:23 -04:00
Fixed broken setmetatable with __gc.
This commit is contained in:
parent
d4addfd8e4
commit
ce081cfc73
@ -737,7 +737,7 @@ sandbox = {
|
||||
local ret = table.pack(pcall(setmetatable, t, mt))
|
||||
rawset(mt, "__gc", gc) -- restore __gc
|
||||
if not ret[1] then error(ret[2], 0) end
|
||||
return table.unpack(ret, 1, ret.n)
|
||||
return table.unpack(ret, 2, ret.n)
|
||||
end
|
||||
end
|
||||
return setmetatable(t, mt)
|
||||
|
Loading…
x
Reference in New Issue
Block a user