r39648 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r39647‎ | r39648 | r39649 >
Date:16:48, 19 August 2008
Author:aaron
Status:old
Tags:
Comment:
minor ui fix
Modified paths:
  • /trunk/extensions/CheckUser/CheckUser_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CheckUser/CheckUser_body.php
@@ -138,7 +138,7 @@
139139 }
140140
141141 protected function doForm( $user, $reason, $checktype, $ip, $xff, $name, $period ) {
142 - global $wgOut, $wgTitle;
 142+ global $wgOut, $wgTitle, $wgUser;
143143 $action = $wgTitle->escapeLocalUrl();
144144 # Fill in requested type if it makes sense
145145 $encipusers = $encipedits = $encuserips = $encuseredits = 0;
@@ -157,9 +157,11 @@
158158 $encuserips = 1;
159159 # Compile our nice form
160160 # User box length should fit things like "2001:0db8:85a3:08d3:1319:8a2e:0370:7344/100/xff"
161 - $wgOut->addWikiText( wfMsg( 'checkuser-summary' ) .
162 - "\n\n[[" . $this->getLogSubpageTitle()->getPrefixedText() . '|' . wfMsg( 'checkuser-showlog' ) . ']]'
163 - );
 161+ if( $wgUser->isAllowed( 'checkuser-log' ) ) {
 162+ $wgOut->addWikiText( wfMsg( 'checkuser-summary' ) .
 163+ "\n\n[[" . $this->getLogSubpageTitle()->getPrefixedText() . '|' . wfMsg( 'checkuser-showlog' ) . ']]'
 164+ );
 165+ }
164166 $form = "<form name='checkuserform' id='checkuserform' action=\"$action\" method='post'>";
165167 $form .= "<fieldset><legend>".wfMsgHtml( "checkuser-query" )."</legend>";
166168 $form .= "<table border='0' cellpadding='2'><tr>";

Status & tagging log