Fixed lume.format() where missing keys were not ignored

This commit is contained in:
rxi 2014-03-03 20:29:11 +00:00
parent bebf8d4fca
commit 778e7f9800

View File

@ -231,7 +231,7 @@ end
function lume.format(str, vars)
local f = function(x) return tostring(vars[x]) or "{" .. x .. "}" end
local f = function(x) return tostring(vars[x] or "{" .. x .. "}") end
return (str:gsub("{(.-)}", f))
end