5,078
edits
No edit summary |
Tag: Undo |
||
Line 2: | Line 2: | ||
function utils.error( ... ) | function utils.error( ... ) | ||
return mw.dumpObject( ... ) | |||
end --[=[ | |||
-- Collect necessary information to display error | -- Collect necessary information to display error | ||
local | local message = select( 1, ... ) or 'There was an error with a template. Are the parameters all correct?' | ||
local etype = select( 2, ... ) or 'Template' | |||
local etype = | local category = select( 3, ... ) or 'Pages containing template errors' | ||
local category = | local template = select( 4, ... ) or nil | ||
local template = | |||
-- Add a warning to the edit preview | -- Add a warning to the edit preview | ||
if template == nil then | if template == nil then | ||
Line 23: | Line 24: | ||
.. ']]' | .. ']]' | ||
end | end | ||
]=] | |||
return utils | return utils |