Add a check for our custom tweak in the in-app notif handling to determine which should be used

This commit is contained in:
Gigiaj 2025-06-08 20:16:44 -05:00
parent a883963314
commit ac5925f293

View file

@ -187,12 +187,15 @@ function MessageNotifications() {
) => {
if (mx.getSyncState() !== 'SYNCING') return;
if (document.hasFocus() && (selectedRoomId === room?.roomId || notificationSelected)) return;
let pushActions = mx.getPushActionsForEvent(mEvent);
const hasInAppTweak = pushActions?.tweaks?.sound === 'cinny_show_banner';
if (
!room ||
!data.liveEvent ||
room.isSpaceRoom() ||
!isNotificationEvent(mEvent) ||
getNotificationType(mx, room.roomId) === NotificationType.Mute
(getNotificationType(mx, room.roomId) === NotificationType.Mute && !hasInAppTweak)
) {
return;
}