|
|
@@ -142,7 +142,13 @@ export default class AbstractNotificationsContainer<P: Props>
|
|
142
|
142
|
* @returns {void}
|
|
143
|
143
|
*/
|
|
144
|
144
|
_onDismissed(uid) {
|
|
145
|
|
- this._clearNotificationDismissTimeout();
|
|
|
145
|
+ const { _notifications } = this.props;
|
|
|
146
|
+
|
|
|
147
|
+ // Clear the timeout only if it's the top notification that's being
|
|
|
148
|
+ // dismissed (the timeout is set only for the top one).
|
|
|
149
|
+ if (!_notifications.length || _notifications[0].uid === uid) {
|
|
|
150
|
+ this._clearNotificationDismissTimeout();
|
|
|
151
|
+ }
|
|
146
|
152
|
|
|
147
|
153
|
this.props.dispatch(hideNotification(uid));
|
|
148
|
154
|
}
|