mirror of
https://github.com/TangentFoxy/lua-sandbox.git
synced 2025-07-28 02:52:22 +00:00
more fiddling with string.rep
This commit is contained in:
@@ -54,10 +54,12 @@ local function run(f, options)
|
||||
string.rep = nil
|
||||
|
||||
setfenv(f, BASE_ENV)
|
||||
local result = f()
|
||||
local ok, result = pcall(f)
|
||||
|
||||
string.rep = string_rep
|
||||
|
||||
if not ok then error(result) end
|
||||
|
||||
return result
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user