Module:Sandbox/Ypnypn/Review: Difference between revisions

Content deleted Content added
No edit summary
length
 
(2 intermediate revisions by the same user not shown)
Line 39:
--infobox
if not string.match(content, '{{Infobox') then
issues['infobox'] = 'falsenone'
end
 
Line 47:
elseif not string.match(content, '%[%[Category:.+%[%[Category:') then
issues['category'] = 'one'
end
 
--length
length = #prose
if length > 100000 then
issues['length'] = 'too long'
elseif length < 10000 then
issues['length'] = 'too short'
end
 
Line 54 ⟶ 62:
function text(issue, details)
 
if issue == 'infobox' and details == 'none' then
return '* There is no infobox.\n'
end
Line 66 ⟶ 74:
end
 
if issue == 'length' then
return '<strong>Error: issue not found! Issue: '..issue..' = '..details..'</strong'
if details == 'too long' then
return '* The article is very long.\n'
elseif details == 'too short' then
return '* The article is very short.\n'
end
end
 
return '<strong><span style="color:red">Error: issuetext not found! Issue:</span> '..issue..' = '..details..'</strong>\n'
end