From: Siebrand Mazeland Date: Thu, 6 Nov 2008 22:09:28 +0000 (+0000) Subject: Update on r43103. Add the 'norollbackdiff' toggle to 'misc', not to 'edit' per sugges... X-Git-Tag: 1.31.0-rc.0~44419 X-Git-Url: http://git.cyclocoop.org/%7B%24admin_url%7Dcompta/comptes/journal.php?a=commitdiff_plain;h=19d147c0a3b2750ca25c47d98579364a2c18da55;p=lhc%2Fweb%2Fwiklou.git Update on r43103. Add the 'norollbackdiff' toggle to 'misc', not to 'edit' per suggestion by Aaron. --- diff --git a/includes/specials/SpecialPreferences.php b/includes/specials/SpecialPreferences.php index 6f88b8b791..bec21cd115 100644 --- a/includes/specials/SpecialPreferences.php +++ b/includes/specials/SpecialPreferences.php @@ -1004,9 +1004,6 @@ class PreferencesForm { 'forceeditsummary', ) ) ); - if( $wgUser->isAllowed( 'rollback' ) ) - $wgOut->addHtml( $this->getToggle( 'norollbackdiff' ) ); - $wgOut->addHtml( '' ); # Recent changes @@ -1118,9 +1115,13 @@ class PreferencesForm { foreach ( $togs as $tname ) { if( !array_key_exists( $tname, $this->mUsedToggles ) ) { - $wgOut->addHTML( $this->getToggle( $tname ) ); + if( $tname == 'norollbackdiff' && $wgUser->isAllowed( 'rollback' ) ) + $wgOut->addHTML( $this->getToggle( $tname ) ); + else + $wgOut->addHTML( $this->getToggle( $tname ) ); } } + $wgOut->addHTML( '' ); wfRunHooks( 'RenderPreferencesForm', array( $this, $wgOut ) );