From 627e6c574ff9ff72418e2058eb5c05da5ad5ee9d Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Fri, 8 Jul 2022 17:52:39 -0500 Subject: [PATCH] Drop invalid notifications --- app/soapbox/actions/notifications.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/app/soapbox/actions/notifications.ts b/app/soapbox/actions/notifications.ts index 0e396b89a..adeb46bf9 100644 --- a/app/soapbox/actions/notifications.ts +++ b/app/soapbox/actions/notifications.ts @@ -89,6 +89,7 @@ const updateNotifications = (notification: APIEntity) => const updateNotificationsQueue = (notification: APIEntity, intlMessages: Record, intlLocale: string, curPath: string) => (dispatch: AppDispatch, getState: () => RootState) => { + if (!notification.type) return; // drop invalid notifications if (notification.type === 'pleroma:chat_mention') return; // Drop chat notifications, handle them per-chat const showAlert = getSettings(getState()).getIn(['notifications', 'alerts', notification.type]);