r61394 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r61393‎ | r61394 | r61395 >
Date:21:19, 22 January 2010
Author:ialex
Status:deferred (Comments)
Tags:
Comment:
* (bug 22221) Special:Interwiki's description on Special:SpecialPages should not say "and edit" for users not having "interwiki" right
Modified paths:
  • /trunk/extensions/Interwiki/SpecialInterwiki_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Interwiki/SpecialInterwiki_body.php
@@ -12,6 +12,13 @@
1313 parent::__construct( 'Interwiki' );
1414 }
1515
 16+ function getDescription() {
 17+ global $wgUser;
 18+
 19+ return wfMsg( $wgUser->isAllowed( 'interwiki' ) ?
 20+ 'interwiki' : 'interwiki-title-norights' );
 21+ }
 22+
1623 /**
1724 * Show the special page
1825 *
@@ -28,11 +35,6 @@
2936 $this->outputHeader();
3037
3138 $admin = $wgUser->isAllowed( 'interwiki' );
32 - if ( $admin ) {
33 - $wgOut->setPageTitle( wfMsg( 'interwiki' ) );
34 - } else {
35 - $wgOut->setPageTitle( wfMsg( 'interwiki-title-norights' ) );
36 - }
3739 $action = $wgRequest->getVal( 'action', $par );
3840
3941 switch( $action ){

Comments

#Comment by Wikinaut (talk | contribs)   21:44, 22 January 2010

perfect! Thanks

Status & tagging log