Module:Hatnote: Difference between revisions
Jump to navigation
Jump to search
add a help link for the hatnote and formatLink functions
>Mr. Stradivarius (add helpLink parameter to makeWikitextError) |
>Mr. Stradivarius (add a help link for the hatnote and formatLink functions) |
||
Line 125: | Line 125: | ||
local display = args[2] | local display = args[2] | ||
if not link then | if not link then | ||
return p.makeWikitextError('no link specified') | return p.makeWikitextError( | ||
'no link specified', | |||
'Template:Format hatnote link#Errors', | |||
args.category | |||
) | |||
end | end | ||
return p._formatLink(link, display) | return p._formatLink(link, display) | ||
Line 172: | Line 176: | ||
local options = {} | local options = {} | ||
if not s then | if not s then | ||
return p.makeWikitextError('no text specified') | return p.makeWikitextError( | ||
'no text specified', | |||
'Template:Hatnote#Errors', | |||
args.category | |||
) | |||
end | end | ||
options.extraclasses = args.extraclasses | options.extraclasses = args.extraclasses |