Skip to content

Commit

Permalink
fix: viewed notifications don't appear as unread
Browse files Browse the repository at this point in the history
  • Loading branch information
becooq81 committed May 25, 2024
1 parent e39b6f8 commit de08709
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ public List<Notification> getUnreadNotificationsForMember(String receiverId) {
.sorted(Comparator.comparing(Notification::getCreatedAt).reversed())
.collect(Collectors.toList());
notifications.forEach(Notification::memberReads);
notificationRepository.saveAll(notifications);
Member recipient = getMemberByLoginID(receiverId);
recipient.resetNotificationCount();
return notifications;
Expand Down

0 comments on commit de08709

Please sign in to comment.