Editing Module:Protection banner
From MINR.ORG WIKI
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone.
Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 173: | Line 173: | ||
function Protection:isProtected() | function Protection:isProtected() | ||
return self.level ~= '*' | return self.level ~= '*' | ||
− | |||
− | |||
− | |||
− | |||
end | end | ||
Line 526: | Line 522: | ||
function Blurb:_makeIntroBlurbParameter() | function Blurb:_makeIntroBlurbParameter() | ||
− | if self._protectionObj | + | if type(self._protectionObj.expiry) == 'number' then |
return self:_getExpandedMessage('intro-blurb-expiry') | return self:_getExpandedMessage('intro-blurb-expiry') | ||
else | else | ||
Line 621: | Line 617: | ||
function Blurb:_makeTooltipBlurbParameter() | function Blurb:_makeTooltipBlurbParameter() | ||
− | if self._protectionObj | + | if type(self._protectionObj.expiry) == 'number' then |
return self:_getExpandedMessage('tooltip-blurb-expiry') | return self:_getExpandedMessage('tooltip-blurb-expiry') | ||
else | else | ||
Line 691: | Line 687: | ||
local action = protectionObj.action | local action = protectionObj.action | ||
local level = protectionObj.level | local level = protectionObj.level | ||
+ | local expiry = protectionObj.expiry | ||
local namespace = protectionObj.title.namespace | local namespace = protectionObj.title.namespace | ||
local reason = protectionObj.reason | local reason = protectionObj.reason | ||
Line 702: | Line 699: | ||
and action == 'edit' | and action == 'edit' | ||
and level == 'sysop' | and level == 'sysop' | ||
− | and not | + | and (not expiry or expiry == 'indef') |
then | then | ||
-- Fully protected modules and templates get the special red "indef" | -- Fully protected modules and templates get the special red "indef" |