[Glitch] Fix all streamed notification types being stored without filtering

Port a7b718c31a to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
Claire
2024-08-12 15:40:29 +02:00
parent 61b2139267
commit 8426c20d34
4 changed files with 59 additions and 10 deletions

View File

@@ -387,12 +387,14 @@ export const notificationGroupsReducer = createReducer<NotificationGroupsState>(
})
.addCase(processNewNotificationForGroups.fulfilled, (state, action) => {
const notification = action.payload;
processNewNotification(
usePendingItems ? state.pendingGroups : state.groups,
notification,
);
updateLastReadId(state);
trimNotifications(state);
if (notification) {
processNewNotification(
usePendingItems ? state.pendingGroups : state.groups,
notification,
);
updateLastReadId(state);
trimNotifications(state);
}
})
.addCase(disconnectTimeline, (state, action) => {
if (action.payload.timeline === 'home') {