diff --git a/sandbox.lua b/sandbox.lua index 98fde7f..b663ca9 100644 --- a/sandbox.lua +++ b/sandbox.lua @@ -76,19 +76,14 @@ local function run(f, options) end end debug.sethook(timeout, "", step) - string.rep = nil local ok, result = pcall(f) cleanup() - if not ok then error(result) end return result end -local sandbox = { run = run } - - -return setmetatable(sandbox, {__call = function(_,f,o) return run(f,o) end}) +return setmetatable({run = run}, {__call = function(_,f,o) return run(f,o) end})