Don't inhibit current room notifications if user has Modal open (#7274)
This commit is contained in:
committed by
GitHub
parent
494af883f3
commit
37bf85489d
@@ -379,11 +379,14 @@ export const Notifier = {
|
||||
}
|
||||
},
|
||||
|
||||
_evaluateEvent: function(ev) {
|
||||
_evaluateEvent: function(ev: MatrixEvent) {
|
||||
const room = MatrixClientPeg.get().getRoom(ev.getRoomId());
|
||||
const actions = MatrixClientPeg.get().getPushActionsForEvent(ev);
|
||||
if (actions && actions.notify) {
|
||||
if (RoomViewStore.getRoomId() === room.roomId && UserActivity.sharedInstance().userActiveRecently()) {
|
||||
if (RoomViewStore.getRoomId() === room.roomId &&
|
||||
UserActivity.sharedInstance().userActiveRecently() &&
|
||||
!Modal.hasDialogs()
|
||||
) {
|
||||
// don't bother notifying as user was recently active in this room
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user