Content deleted Content added
avoid table.insert (2x speed improvement!) |
remove trailing newline |
||
Line 32:
if not ns or not mw.site.namespaces[ns] then
generate_transclusion('Template:' .. item)
output[#output + 1] = '* [[Template:' .. item .. ']]
elseif (ns == "File") or (ns == "Image") then
generate_transclusion(item)
output[#output + 1] = '* [[:' .. item .. ']]
elseif ns == "Category" then
generate_transclusion(item)
output[#output + 1] = '* [[:' .. item .. ']]
elseif rest ~= '' then
generate_transclusion(item)
output[#output + 1] = '* [[' .. item .. ']]
end
end
Line 48:
return ""
else
return table.concat(output, '\n')
end
end
|