Skip to content

Commit 209aec6

Browse files
authored
fix: compare account uuids (#2674)
Signed-off-by: Adam Setch <adam.setch@outlook.com>
1 parent 67785d6 commit 209aec6

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/renderer/hooks/useNotifications.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ import {
1414
markNotificationThreadAsDone,
1515
markNotificationThreadAsRead,
1616
} from '../utils/api/client';
17+
import { getAccountUUID } from '../utils/auth/utils';
1718
import {
1819
areAllAccountErrorsSame,
1920
doesAllAccountsHaveErrors,
@@ -83,8 +84,9 @@ export const useNotifications = (): NotificationsState => {
8384
async (account: Account) => {
8485
setStatus('loading');
8586

87+
const accountUUID = getAccountUUID(account);
8688
const updatedNotifications = notifications.filter(
87-
(notification) => notification.account !== account,
89+
(notification) => getAccountUUID(notification.account) !== accountUUID,
8890
);
8991

9092
setNotifications(updatedNotifications);

0 commit comments

Comments
 (0)