From ccf30040e3066835ef2c351b78225b06a4817b9e Mon Sep 17 00:00:00 2001 From: Alexandre Emsenhuber Date: Sun, 29 Nov 2009 15:10:45 +0000 Subject: [PATCH] * (bug 21679) "Edit block reasons" link at the bottom of Special:Blockip is now only displayed to the users that have "editinterface" right --- RELEASE-NOTES | 2 ++ includes/specials/SpecialBlockip.php | 16 +++++++++------- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 98e56ae241..a87e6a0cb7 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -650,6 +650,8 @@ Hopefully we will remove this configuration var soon) PHP's memcached extension * (bug 21650) Both calls to SkinTemplateTabs hook are now compatible * (bug 21672) Add missing Accept-Language to both Vary and XVO headers +* (bug 21679) "Edit block reasons" link at the bottom of Special:Blockip is now + only displayed to the users that have "editinterface" right == API changes in 1.16 == diff --git a/includes/specials/SpecialBlockip.php b/includes/specials/SpecialBlockip.php index 276f77a4ff..c3e5dcc7af 100644 --- a/includes/specials/SpecialBlockip.php +++ b/includes/specials/SpecialBlockip.php @@ -696,13 +696,15 @@ class IPBlockForm { $links[] = $this->getContribsLink( $skin ); $links[] = $this->getUnblockLink( $skin ); $links[] = $this->getBlockListLink( $skin ); - $title = Title::makeTitle( NS_MEDIAWIKI, 'Ipbreason-dropdown' ); - $links[] = $skin->link( - $title, - wfMsgHtml( 'ipb-edit-dropdown' ), - array(), - array( 'action' => 'edit' ) - ); + if ( $wgUser->isAllowed( 'editinterface' ) ) { + $title = Title::makeTitle( NS_MEDIAWIKI, 'Ipbreason-dropdown' ); + $links[] = $skin->link( + $title, + wfMsgHtml( 'ipb-edit-dropdown' ), + array(), + array( 'action' => 'edit' ) + ); + } return ''; } -- 2.20.1