Module:Hatnote: Difference between revisions

Remove stray space per edit request; update comment and error message for move of Template:Format hatnote link to Template:Format link in 2014
(don't add pages in the user namespace to Category:Hatnote templates with errors)
(Remove stray space per edit request; update comment and error message for move of Template:Format hatnote link to Template:Format link in 2014)
Line 130:
-- with colons if necessary, and links to sections are detected and displayed
-- with " § " as a separator rather than the standard MediaWiki "#". Used in
-- the {{format hatnote link}} template.
--------------------------------------------------------------------------------
 
Line 141:
return p.makeWikitextError(
'no link specified',
'Template:Format hatnote link#Errors',
args.category
)
Line 231:
local page = maybeItalicize(parsed.page, options.italicizePage)
local section = maybeItalicize(parsed.section, options.italicizeSection)
if sectionnot page or page == '' then
display = string.format('§ %s', section)
elseif section then
display = string.format('%s § %s', page, section)
else
Anonymous user