http://www.mediawiki.org/wiki/Special:Code/MediaWiki/90874

Revision: 90874
Author:   happy-melon
Date:     2011-06-27 13:48:01 +0000 (Mon, 27 Jun 2011)
Log Message:
-----------
Follow-up r88738: this check is no longer needed since r88750.

Modified Paths:
--------------
    trunk/phase3/includes/Block.php

Modified: trunk/phase3/includes/Block.php
===================================================================
--- trunk/phase3/includes/Block.php     2011-06-27 12:57:23 UTC (rev 90873)
+++ trunk/phase3/includes/Block.php     2011-06-27 13:48:01 UTC (rev 90874)
@@ -988,11 +988,6 @@
         *     not be the same as the target you gave if you used $vagueTarget!
         */
        public static function newFromTarget( $specificTarget, $vagueTarget = 
null, $fromMaster = false ) {
-               # (bug 29116) passing $vagueTarget = '' is not unreasonable 
here, but int(0)
-               # is a valid username, so we can't just use weak comparisons.
-               if( $vagueTarget === '' ){
-                       $vagueTarget = null;
-               }
 
                list( $target, $type ) = self::parseTarget( $specificTarget );
                if( $type == Block::TYPE_ID || $type == Block::TYPE_AUTO ){
@@ -1000,7 +995,8 @@
 
                } elseif( $target === null && $vagueTarget == '' ){
                        # We're not going to find anything useful here
-                       # Be aware that the == '' check is explicit, since 
empty values will be passed by some callers.
+                       # Be aware that the == '' check is explicit, since 
empty values will be
+                       # passed by some callers (bug 29116)
                        return null;
 
                } elseif( in_array( $type, array( Block::TYPE_USER, 
Block::TYPE_IP, Block::TYPE_RANGE, null ) ) ) {


_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to