Content deleted Content added
Fred Gandt (talk | contribs) sync |
Fred Gandt (talk | contribs) correction for redirect title conversion; will properly test later; so tired |
||
Line 54:
end
local function getExplicitDescription( name, new_title )
local new_title = mw.title.new( name )▼
new_title = new_title.redirectTarget or new_title▼
local page_content = new_title:getContent()
if isEmpty( page_content ) then
Line 156 ⟶ 154:
objectify_alarm = args.objectify_alarm
report_redlinks = args.report_redlinks
local
if isEmpty(
▲ new_title = new_title.redirectTarget or new_title
local name = new_title.prefixedText
local fallback = args.fallback
if isSisterProjectLink( name ) then return fallback end
Line 172 ⟶ 175:
local result
if only == 'explicit' then result = getExplicitDescription(
elseif only == 'wikidata' then result = getWikidataDescription( name, lang )
elseif prefer == 'explicit' then
result = getExplicitDescription(
if isEmpty( result ) then result = getWikidataDescription( name, lang, true )
elseif isNone( result ) then
Line 184 ⟶ 187:
end
end
elseif prefer == 'wikidata' then result = getWikidataDescription( name, lang ) or getExplicitDescription(
if isNone( result ) then result = nil end
|