Mooeypoo has uploaded a new change for review. https://gerrit.wikimedia.org/r/242638
Change subject: Mark notifications as automatically read only after the popup loads ...................................................................... Mark notifications as automatically read only after the popup loads We've corrected this behavior for updating seenTime but not for setting the notifications as read if the widget is configured as 'markReadWhenSeen' which produced unexpected issues with updating alerts. This is fixed in this commit. Change-Id: I4d2420a81d2b8409749ad1621b2d56bdd14e8c6e --- M modules/ooui/mw.echo.ui.NotificationBadgeWidget.js 1 file changed, 4 insertions(+), 5 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Echo refs/changes/38/242638/1 diff --git a/modules/ooui/mw.echo.ui.NotificationBadgeWidget.js b/modules/ooui/mw.echo.ui.NotificationBadgeWidget.js index b23ca86..4bad331 100644 --- a/modules/ooui/mw.echo.ui.NotificationBadgeWidget.js +++ b/modules/ooui/mw.echo.ui.NotificationBadgeWidget.js @@ -260,11 +260,6 @@ // Log impressions mw.echo.logger.logNotificationImpressions( this.type, idArray, mw.echo.Logger.static.context.popup ); - - // // Mark notifications as 'read' if markReadWhenSeen is set to true - if ( widget.popup.isVisible() && widget.markReadWhenSeen ) { - return widget.notificationsModel.markAllRead(); - } } ) .then( // Success @@ -329,6 +324,10 @@ if ( widget.popup.isVisible() ) { // Update seen time widget.notificationsModel.updateSeenTime(); + // Mark notifications as 'read' if markReadWhenSeen is set to true + if ( widget.markReadWhenSeen ) { + widget.notificationsModel.markAllRead(); + } } } ); this.hasRunFirstTime = true; -- To view, visit https://gerrit.wikimedia.org/r/242638 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I4d2420a81d2b8409749ad1621b2d56bdd14e8c6e Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Echo Gerrit-Branch: master Gerrit-Owner: Mooeypoo <mor...@gmail.com> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits