Remove cache use in setNewtalk, as nothing reads from that

Change-Id: Ia094fa99be49816b48e35aeb695b5d9558fd1d28
This commit is contained in:
Aaron Schulz 2015-04-27 16:45:58 -07:00
parent 3cb979496f
commit 76f961097a

View file

@ -2252,8 +2252,6 @@ class User implements IDBAccessObject {
* page. Ignored if null or !$val.
*/
public function setNewtalk( $val, $curRev = null ) {
global $wgMemc;
if ( wfReadOnly() ) {
return;
}
@ -2275,12 +2273,6 @@ class User implements IDBAccessObject {
$changed = $this->deleteNewtalk( $field, $id );
}
if ( $this->isAnon() ) {
// Anons have a separate memcached space, since
// user records aren't kept for them.
$key = wfMemcKey( 'newtalk', 'ip', $id );
$wgMemc->set( $key, $val ? 1 : 0, 1800 );
}
if ( $changed ) {
$this->invalidateCache();
}