Module:Redirect-distinguish: Difference between revisions

m
15 revisions imported from wikipedia:Module:Redirect-distinguish: All aboard the import train again. Originally imported from English Wikipedia.
(Updated maintenance category output to handle new Category:Articles with redirect hatnotes impacted by RfD case)
m (15 revisions imported from wikipedia:Module:Redirect-distinguish: All aboard the import train again. Originally imported from English Wikipedia.)
 
(5 intermediate revisions by 5 users not shown)
Line 20:
end
local redirectTitle = mw.title.new(args[1])
local currentTitle = currentTitle or mw.title.getCurrentTitle()
if string.match(args[1], 'REDIRECT%d+') or args[1] == 'TERM' then
if
if string.match(args[1], 'REDIRECT%d+') or args[1] == 'TERM' then
args[1] == 'TERM' or
currentTitle.namespace ~= 0
then
--do nothing
elseif not redirectTitle or not redirectTitle.exists then
Line 44 ⟶ 49:
local redirect = table.remove(args, 1)
local text = string.format(
'"%s" redirects here. It is notNot to be confused with %s.',
redirect,
mHatlist.orList(args, true)