self::selectFields(),
array( 'user_id' => $this->mId ),
__METHOD__,
- ( $flags & self::READ_LOCKING == self::READ_LOCKING )
+ ( ( $flags & self::READ_LOCKING ) == self::READ_LOCKING )
? array( 'LOCK IN SHARE MODE' )
: array()
);
* Called implicitly from invalidateCache() and saveSettings().
*/
public function clearSharedCache() {
- $this->load();
- if ( $this->mId ) {
+ $id = $this->getId();
+ if ( $id ) {
$cache = ObjectCache::getMainWANInstance();
-
- $cache->delete( wfMemcKey( 'user', 'id', $this->mId ) );
+ $cache->delete( wfMemcKey( 'user', 'id', $id ) );
}
}