Skip to content

Commit

Permalink
Merge pull request #178 from bcgov/stories/ECER-779
Browse files Browse the repository at this point in the history
Adjust unreadMessageCount in communication handler
  • Loading branch information
pcatkins authored Apr 2, 2024
2 parents 57c7629 + 699870a commit 8e05cab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ECER.Managers.Registry/CommunicationHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ public static async Task<CommunicationsStatusResults> Handle(Contract.Communicat
ByRegistrantId = query.ByRegistrantId,
ByStatus = statuses,
});

var unreadCount = communications.Where(c => c.Acknowledged).ToList().Count; // it does not support Any
var unreadCount = communications.Where(c => !c.Acknowledged).ToList().Count; // it does not support Any
var hasUnread = unreadCount > 0;

var communicationsStatus = new Contract.Communications.CommunicationsStatus() { HasUnread = hasUnread, Count = unreadCount };
Expand Down

0 comments on commit 8e05cab

Please sign in to comment.