Module:LuaCall: Difference between revisions

From Test Wiki
Content deleted Content added
How did I foul that up? It was too simple to foul up... Undid revision 585493232 by Wnt (talk)
duh...
Line 29: Line 29:
end
end
local reserved_arraypart=_G
local reserved_arraypart=_G
while mw.ustring.match(reserved_function,"%.") do
repeat
reserved_functionpart,reserved_function=mw.ustring.match(reserved_function,"^(%a[^%.]*)%.(.*)$")
reserved_functionpart,reserved_function=mw.ustring.match(reserved_function,"^(%a[^%.]*)%.(.*)$")
reserved_arraypart=reserved_arraypart[reserved_functionpart]
reserved_arraypart=reserved_arraypart[reserved_functionpart]
end
until not mw.ustring.match(reserved_function,"%.")
local reserved_call=reserved_arraypart[reserved_function]
local reserved_call=reserved_arraypart[reserved_function]
if type(reserved_call)~="function" then
if type(reserved_call)~="function" then