71 $casTimestamp = $this->params[
'notifTime'] ?? $this->params[
'curTime'];
74 $dbw = MediaWikiServices::getInstance()->getConnectionProvider()->getPrimaryDatabase();
81 $casTimeCond = $dbw->expr(
'wl_notificationtimestamp',
'<', $dbw->timestamp( $casTimestamp ) );
84 $wlId = $dbw->newSelectQueryBuilder()
88 'wl_user' => $this->params[
'userid'],
89 'wl_namespace' => $this->title->getNamespace(),
90 'wl_title' => $this->title->getDBkey(),
92 ] )->caller( __METHOD__ )->fetchField();
97 $dbw->newUpdateQueryBuilder()
98 ->update(
'watchlist' )
99 ->set( [
'wl_notificationtimestamp' => $dbw->timestampOrNull( $this->params[
'notifTime'] ) ] )
100 ->where( [
'wl_id' => (
int)$wlId, $casTimeCond ] )
101 ->caller( __METHOD__ )->execute();