Skip to content

Commit

Permalink
Fix “Mark every notification as read” not updating the read marker if…
Browse files Browse the repository at this point in the history
… scrolled down (mastodon#32385)
  • Loading branch information
ClearlyClaire committed Oct 14, 2024
1 parent f75eb1a commit e018e63
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app/javascript/mastodon/reducers/notification_groups.ts
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,10 @@ export const notificationGroupsReducer = createReducer<NotificationGroupsState>(
compareId(state.lastReadId, mostRecentGroup.page_max_id) < 0
)
state.lastReadId = mostRecentGroup.page_max_id;
commitLastReadId(state);

// We don't call `commitLastReadId`, because that is conditional
// and we want to unconditionally update the state instead.
state.readMarkerId = state.lastReadId;
})
.addCase(fetchMarkers.fulfilled, (state, action) => {
if (
Expand Down

0 comments on commit e018e63

Please sign in to comment.