r18915 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r18914‎ | r18915 | r18916 >
Date:07:57, 7 January 2007
Author:werdna
Status:old
Tags:
Comment:
Well there was no problem in the first place. Nice work Werdna
Modified paths:
  • /trunk/phase3/includes/Block.php (modified) (history)
  • /trunk/phase3/includes/User.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/User.php
@@ -836,6 +836,11 @@
837837 $this->mBlockedby = 0;
838838 $ip = wfGetIP();
839839
 840+ if ($this->isAllowed( 'ipblock-exempt' ) ) {
 841+ # Exempt from all types of IP-block
 842+ $ip = '';
 843+ }
 844+
840845 # User/IP blocking
841846 $this->mBlock = new Block();
842847 $this->mBlock->fromMaster( !$bFromSlave );
Index: trunk/phase3/includes/Block.php
@@ -126,12 +126,6 @@
127127 if ( $this->loadFromResult( $res, $killExpired ) ) {
128128 return true;
129129 }
130 -
131 - $userObject = User::newFromId($user);
132 -
133 - if ($userObject->isAllowed('ipblock-exempt') ) {
134 - $address = '';
135 - }
136130 }
137131
138132 # Try IP block