X-Git-Url: https://git.cyclocoop.org/?a=blobdiff_plain;f=includes%2FUserRightsProxy.php;h=56bb73f8fcb0691394e2f7c9df55aa5ae9764a6e;hb=6a3bc6294a1b5b42a4d0f7062152d892e0aed1d3;hp=cd5dff84f339237335a6bfc72b40c6f6df21050f;hpb=6bc4c21ed1914abe31507fa132909e7f947e6075;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/UserRightsProxy.php b/includes/UserRightsProxy.php index cd5dff84f3..56bb73f8fc 100644 --- a/includes/UserRightsProxy.php +++ b/includes/UserRightsProxy.php @@ -74,7 +74,7 @@ class UserRightsProxy { */ public static function whoIs( $database, $id, $ignoreInvalidDB = false ) { $user = self::newFromId( $database, $id, $ignoreInvalidDB ); - if( $user ) { + if ( $user ) { return $user->name; } else { return false; @@ -114,12 +114,12 @@ class UserRightsProxy { */ private static function newFromLookup( $database, $field, $value, $ignoreInvalidDB = false ) { $db = self::getDB( $database, $ignoreInvalidDB ); - if( $db ) { + if ( $db ) { $row = $db->selectRow( 'user', array( 'user_id', 'user_name' ), array( $field => $value ), __METHOD__ ); - if( $row !== false ) { + if ( $row !== false ) { return new UserRightsProxy( $db, $database, $row->user_name, intval( $row->user_id ) ); @@ -138,8 +138,8 @@ class UserRightsProxy { */ public static function getDB( $database, $ignoreInvalidDB = false ) { global $wgDBname; - if( self::validDatabase( $database ) ) { - if( $database == $wgDBname ) { + if ( self::validDatabase( $database ) ) { + if ( $database == $wgDBname ) { // Hmm... this shouldn't happen though. :) return wfGetDB( DB_MASTER ); } else {