Difference between revisions of "Module:Effective protection level"
Module:Effective protection level (view source)
Revision as of 04:01, 16 September 2014
, 04:01, 16 September 2014must be subpage too
>Jackmcbarn (test content models rather than page names, to match MediaWiki) |
>Jackmcbarn (must be subpage too) |
||
Line 27: | Line 27: | ||
if title.namespace == 8 then -- MediaWiki namespace | if title.namespace == 8 then -- MediaWiki namespace | ||
return 'sysop' | return 'sysop' | ||
elseif title.namespace == 2 and ( title.contentModel == 'javascript' or title.contentModel == 'css' ) then -- user JS or CSS page | elseif title.namespace == 2 and title.isSubpage and ( title.contentModel == 'javascript' or title.contentModel == 'css' ) then -- user JS or CSS page | ||
return 'sysop' | return 'sysop' | ||
end | end |