diff --git a/functions/src/create-notification.ts b/functions/src/create-notification.ts index 4c42b00e..56493043 100644 --- a/functions/src/create-notification.ts +++ b/functions/src/create-notification.ts @@ -411,6 +411,7 @@ export const createGroupCommentNotification = async ( group: Group, idempotencyKey: string ) => { + if (toUserId === fromUser.id) return const notificationRef = firestore .collection(`/users/${toUserId}/notifications`) .doc(idempotencyKey) diff --git a/web/components/nav/sidebar.tsx b/web/components/nav/sidebar.tsx index 5c3b9128..821d1397 100644 --- a/web/components/nav/sidebar.tsx +++ b/web/components/nav/sidebar.tsx @@ -294,7 +294,7 @@ function GroupsList(props: { if ( notification.isSeenOnHref === currentPage || // Old chat style group chat notif ended just with the group slug - notification.isSeenOnHref?.endsWith(currentPageGroupSlug) || + notification.isSeenOnHref?.includes(currentPageGroupSlug) || // They're on the home page, so if they've a chat notif, they're seeing the chat (notification.isSeenOnHref?.endsWith(GROUP_CHAT_SLUG) && currentPage.endsWith(currentPageGroupSlug))