require('strict')local yesno = require('Module:Yesno')local getArgs = require('Module:Arguments').getArgslocal TableTools = require('Module:TableTools')local p =
local newPageHeader = '
function p.main(frame) local args = getArgs(frame) return p._main(args)end
function p._main(args) local outText = local master = mw.title.getCurrentTitle.subpageText local socks = local ips = --Wikipedia:Sockpuppet investigations/SPI/Blank report template header if not mw.title.getCurrentTitle.exists then outText = string.gsub(newPageHeader, '__SUBPAGENAME__', master) end local status = if args.status then status = args.status elseif args.admincomment then status = 'close' elseif yesno(args.checkuser) then status = 'CUrequest' end outText = outText .. '
\n\n' --SPI report outText = outText .. '
\n' if args.socksraw then outText = outText .. args.socksraw .. '\n' -- Twinkle uses this to pass in reports (and loads are filed this way), -- so parse the reports for use by the tools section local socksraw = mw.ustring.gsub(args.socksraw, '', ) --rm comments local sockMatches = mw.ustring.gmatch(socksraw, '') local ipMatches = mw.ustring.gmatch(socksraw, '') for i in sockMatches do socks[#socks + 1] = i end for i in ipMatches do ips[#ips + 1] = i end else -- loop over ip# and sock# args (copied from) for k, v in pairs(args) do if type(k)
'sock' then socks[num] = v elseif prefix
\n' .. '\'\'Accused parties may also comment/discuss in this section below. See Defending yourself against claims.\'\'' .. '\n\n
\n' if args.admincomment then outText = outText .. args.admincomment end outText = outText .. '\n\n----' return outTextend
return p