Page MenuHomePhabricator

register user rights only if wgNoticeInfrastructure is true
Closed, ResolvedPublic


The special page [[Special:CentralNotice]] is only available on wikis with $wgNoticeInfrastructure = true. It is possible to register the corrosponding user rights together with the special page? There is no need for unused user rights on wikis without the special page.

The user rights are shown on all wikis, but the special page only on [[meta:]] ($wgNoticeInfrastructure = ($wgDBname == 'metawiki')). Moving the user rights within that if, will fix that. Or it is better to change the setting of wmf and set the user rights to false on non-metawiki?


Version: unspecified
Severity: enhancement



Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 11:12 PM
bzimport set Reference to bz26377.
bzimport added a subscriber: Unknown Object (MLST).

What user rights are you referring to? I wasn't aware that there were any special user rights associated with CentralNotice.

The user rights "centralnotice-admin" and "centralnotice-translate" in CentralNotice.php.

revert with r79780.

Why it is possible to add special pages corrosponding to wgNoticeInfrastructure, but not user rights?

Have you set the globals at the begin of the function? $wgSpecialPages is there.

I'll take a look at this again. I'm not sure why it failed, but may have something to do with the loading order. The user right (in this case) needs to be loaded after the config files are read (in order to fix this bug), but perhaps inside the extension functions is too late for it to have effect.

This is still confusing, when the local [[Special:ListGroupRights]] shows the user right 'centralnotice-admin' for sysop, but [[Special:CentralNotice]] does not exists locally.

Would be nice, when someone can have a look. Thanks.

Looks like this was fixed in

Yes, it is fixed now. Thanks for the hint

Umherirrender assigned this task to hoo.
Umherirrender set Security to None.
Umherirrender removed a subscriber: wikibugs-l-list.
Diskdrive15 raised the priority of this task from Low to Unbreak Now!.Jul 13 2021, 3:53 PM
Diskdrive15 set Due Date to Jul 13 2021, 12:00 AM.
RhinosF1 lowered the priority of this task from Unbreak Now! to Low.Jul 13 2021, 4:46 PM
RhinosF1 removed Due Date.