Skip to content

Commit

Permalink
Merge pull request #37672 from software-mansion-labs/ideal-nav/fix-bo…
Browse files Browse the repository at this point in the history
…ld-issue

Fix issues with the bold (unread) status on Workspace Item
  • Loading branch information
Hayata Suenaga authored Mar 25, 2024
2 parents 5cc5347 + 2c169b1 commit c1947c2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/libs/WorkspacesSettingsUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,9 @@ function getWorkspacesUnreadStatuses(): Record<string, boolean> {
return;
}

workspacesUnreadStatuses[policyID] = ReportUtils.isUnread(report);
// When the only message of a report is deleted lastVisibileActionCreated is not reset leading to wrongly
// setting it Unread so we add additional condition here to avoid read workspace indicator from being bold.
workspacesUnreadStatuses[policyID] = ReportUtils.isUnread(report) && !!report.lastActorAccountID;
});

return workspacesUnreadStatuses;
Expand Down

0 comments on commit c1947c2

Please sign in to comment.