From 9dd32f7dbaa7d7e59490b3c228777c9b858cf5b9 Mon Sep 17 00:00:00 2001 From: Hunter Miller Date: Fri, 9 Feb 2024 15:48:11 -0600 Subject: [PATCH] unread-count: referencing wrong unreads --- ui/src/logic/useMessagesUnreadCount.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/src/logic/useMessagesUnreadCount.ts b/ui/src/logic/useMessagesUnreadCount.ts index 9e16ba9ecb..7adfd56af7 100644 --- a/ui/src/logic/useMessagesUnreadCount.ts +++ b/ui/src/logic/useMessagesUnreadCount.ts @@ -45,10 +45,10 @@ export default function useMessagesUnreadCount(): number { pins .filter((pin) => whomIsNest(pin)) .reduce((accum, whom) => { - const unread = dmUnreads[whom]; + const unread = channelUnreads[whom]; return unread?.count > 0 ? accum + 1 : accum; }, 0), - [pins, dmUnreads] + [pins, channelUnreads] ); const unreadCount = useMemo(() => {