mail: Still update the notification timestamp for bot edits
This is not super optimal but keeps the highlighted functionality. Bug: T356984 Change-Id: I7f1b6f2adcbb22703f52d7ac0e4322379f81ebdc
This commit is contained in:
parent
f125422b7d
commit
f40a4952ff
1 changed files with 6 additions and 6 deletions
|
|
@ -146,12 +146,7 @@ class EmailNotification {
|
|||
|
||||
// update wl_notificationtimestamp for watchers
|
||||
$watchers = [];
|
||||
if (
|
||||
(
|
||||
$config->get( MainConfigNames::EnotifWatchlist ) ||
|
||||
$config->get( MainConfigNames::ShowUpdatedMarker )
|
||||
) && !$mwServices->getUserFactory()->newFromAuthority( $editor )->isBot()
|
||||
) {
|
||||
if ( $config->get( MainConfigNames::EnotifWatchlist ) || $config->get( MainConfigNames::ShowUpdatedMarker ) ) {
|
||||
$watchers = $mwServices->getWatchedItemStore()->updateNotificationTimestamp(
|
||||
$editor->getUser(),
|
||||
$title,
|
||||
|
|
@ -159,6 +154,11 @@ class EmailNotification {
|
|||
);
|
||||
}
|
||||
|
||||
// Don't send email for bots
|
||||
if ( $mwServices->getUserFactory()->newFromAuthority( $editor )->isBot() ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$sendEmail = true;
|
||||
// $watchers deals with $wgEnotifWatchlist.
|
||||
// If nobody is watching the page, and there are no users notified on all changes
|
||||
|
|
|
|||
Loading…
Reference in a new issue