Module:Article list and Module:Article list/sandbox: Difference between pages
(Difference between pages)
imported>Legoktm Replace Module:No globals with require( "strict" ) |
imported>WOSlinker use require('strict') instead of require('Module:No globals') |
||
Line 1: | Line 1: | ||
local p = {}; | |||
require('strict') | require('strict') | ||
local function makelink(link) | local function makelink(link) | ||
Line 91: | Line 90: | ||
end | end | ||
end | end | ||
local output = '<ul>'..table.concat(links2) | local output = '<ul>'..table.concat(links2)..'</ul>' | ||
if mw.title.getCurrentTitle():inNamespace(10) then | if mw.title.getCurrentTitle():inNamespace(10) then | ||
output = output..notes | output = output..notes | ||
end | end | ||
return output | return output | ||
end | end | ||
Line 102: | Line 101: | ||
local pargs = frame:getParent().args | local pargs = frame:getParent().args | ||
local input = args[1] or pargs[1] | local input = args[1] or pargs[1] | ||
if input == nil then | if input == nil then | ||
return nil | return nil | ||
Line 123: | Line 118: | ||
end | end | ||
end | end | ||
return "{{" | return "{{Article list|"..table.concat(qidlist,", ").."}}" | ||
end | end | ||
return p | return p |