X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FUserRightsProxy.php;h=a19f6984f257f32c2030584ab5ad7ca9b621305d;hb=c175b53c0e4bf06a00345d15cd370258f41ba865;hp=3be58473207ca9e052807ad817d823a0267def6e;hpb=25bdfe5dc8d2a106278b65e8e5785f51b7034317;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/UserRightsProxy.php b/includes/UserRightsProxy.php index 3be5847320..a19f6984f2 100644 --- a/includes/UserRightsProxy.php +++ b/includes/UserRightsProxy.php @@ -114,7 +114,8 @@ class UserRightsProxy { */ private static function newFromLookup( $database, $field, $value, $ignoreInvalidDB = false ) { global $wgSharedDB, $wgSharedTables; - // If the user table is shared, perform the user query on it, but don't pass it to the UserRightsProxy, + // If the user table is shared, perform the user query on it, + // but don't pass it to the UserRightsProxy, // as user rights are normally not shared. if ( $wgSharedDB && in_array( 'user', $wgSharedTables ) ) { $userdb = self::getDB( $wgSharedDB, $ignoreInvalidDB ); @@ -277,8 +278,8 @@ class UserRightsProxy { array( 'user_id' => $this->id ), __METHOD__ ); - global $wgMemc; + $cache = ObjectCache::getMainWANInstance(); $key = wfForeignMemcKey( $this->database, false, 'user', 'id', $this->id ); - $wgMemc->delete( $key ); + $cache->delete( $key ); } }