Lua error in mw.text.lua at line 25: bad argument #1 to 'match' (string expected, got nil).
local p = {}
function p.main(frame)
local argsToReturn = {}
local extra = {}
for k,v in pairs({'lat', 'long', 'mark', 'marksize', 'label', 'link', 'label_size', 'position'}) do
argsToReturn[k] = string.format("%s = %q", v, mw.text.trim(frame.args[v]))
frame.args[v] = nil
end
if mw.text.trim(frame.args[1]) == 'Syria' then frame.args[1] = nil end
for k,v in pairs(frame.args) do
table.insert(extra, 'EXTRA ' .. k .. ' = ' .. v)
end
return '{ ' .. table.concat(argsToReturn, ', ') .. ' }' .. table.concat(extra, ', ')
end
return p