Index: trunk/phase3/includes/Block.php |
— | — | @@ -988,11 +988,6 @@ |
989 | 989 | * not be the same as the target you gave if you used $vagueTarget! |
990 | 990 | */ |
991 | 991 | public static function newFromTarget( $specificTarget, $vagueTarget = null, $fromMaster = false ) { |
992 | | - # (bug 29116) passing $vagueTarget = '' is not unreasonable here, but int(0) |
993 | | - # is a valid username, so we can't just use weak comparisons. |
994 | | - if( $vagueTarget === '' ){ |
995 | | - $vagueTarget = null; |
996 | | - } |
997 | 992 | |
998 | 993 | list( $target, $type ) = self::parseTarget( $specificTarget ); |
999 | 994 | if( $type == Block::TYPE_ID || $type == Block::TYPE_AUTO ){ |
— | — | @@ -1000,7 +995,8 @@ |
1001 | 996 | |
1002 | 997 | } elseif( $target === null && $vagueTarget == '' ){ |
1003 | 998 | # We're not going to find anything useful here |
1004 | | - # Be aware that the == '' check is explicit, since empty values will be passed by some callers. |
| 999 | + # Be aware that the == '' check is explicit, since empty values will be |
| 1000 | + # passed by some callers (bug 29116) |
1005 | 1001 | return null; |
1006 | 1002 | |
1007 | 1003 | } elseif( in_array( $type, array( Block::TYPE_USER, Block::TYPE_IP, Block::TYPE_RANGE, null ) ) ) { |