Page MenuHomePhabricator

Phase out right-related globals
Closed, ResolvedPublic


Things like $wgSysopUserBans, $wgSysopRangeBans, $wgSysopEmailBans (and any similar ones?) should be phased out, turned into proper rights for $wgGroupPermissions and considered deprecated.

  • $wgSysopUserBans
  • $wgSysopRangeBans
  • $wgSysopEmailBans



Event Timeline

bzimport raised the priority of this task from to Low.Nov 21 2014, 10:38 PM
bzimport set Reference to bz18807.
bzimport added a subscriber: Unknown Object (MLST).
demon created this task.May 15 2009, 4:59 PM
Reedy added a comment.Nov 29 2010, 1:27 AM

Making the changes isn't difficult. Just how the hell do we go about deprecating globals, making sure they work for x future versions (yay, backcompat :/)..?

Or do we just do it, and mark it in the release notes as a breaking change? (How many of these are used in extensions [Not looked myself, as I'm venting, whilst procrastinating from sleep])

Or would we do something like

$blah = false;
if ( $wgUser->isAllowed( 'blahaction' ) ) {
$blah = true;
} else {
global $wgBlahAction;

if ( isset( $wgBlahAction ) && $wgBlahAction ) {
//Maybe whinge about being deprecated
$blah = true;


if ( $blah ) {
//Do/allow optional shizz here

Reedy added a comment.Jan 10 2011, 4:59 AM

Ping, Chad?

We should come up with a solution like the one in Comment 2 for reducing the globals Bug #9968 wrote:

Most of Setup.php is configuration B/C; I think we probably need a clear-out and documentation blitz in there.

(In reply to Chad H. from comment #0)

Things like $wgSysopUserBans, $wgSysopRangeBans, $wgSysopEmailBans (and any

Only one remaining is $wgSysopEmailBans.

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptFeb 17 2016, 9:07 PM
DannyS712 claimed this task.Sep 6 2019, 6:58 AM
DannyS712 updated the task description. (Show Details)
DannyS712 removed a subscriber: wikibugs-l-list.
DannyS712 added a subscriber: DannyS712.
Restricted Application added a project: User-DannyS712. · View Herald TranscriptSep 6 2019, 7:00 AM
DannyS712 moved this task from Unsorted to In progress on the User-DannyS712 board.
DannyS712 closed this task as Resolved.Nov 18 2019, 4:12 AM
DannyS712 updated the task description. (Show Details)
DannyS712 moved this task from In progress to Merged on the User-DannyS712 board.Nov 26 2019, 11:53 AM