Commit 55b06dd0 authored by Gio's avatar Gio

utils.expandVars now support literal table index as variable names

parent ba6d1e08
......@@ -114,7 +114,11 @@ function utils.expandVars(s, ...)
code = code:sub(2, -2)
else
local n = tonumber(code)
if n then v = args[n] end
if n then
v = args[n]
else
v = args[code]
end
end
if not v then
v, err = loadstring("return "..code)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment