From 7c1bf993180d354eab59f315e09bdd4121eb32fc Mon Sep 17 00:00:00 2001 From: Stephen Zhou <38493346+hyoban@users.noreply.github.com> Date: Tue, 8 Jul 2025 00:01:02 +0800 Subject: [PATCH] fix: mark read for inbox entry --- packages/internal/store/src/unread/store.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/packages/internal/store/src/unread/store.ts b/packages/internal/store/src/unread/store.ts index d5fb46c15..a029d9dc0 100644 --- a/packages/internal/store/src/unread/store.ts +++ b/packages/internal/store/src/unread/store.ts @@ -186,6 +186,7 @@ class UnreadSyncService { if (!entry || entry.read === read || (!entry.feedId && !entry.inboxHandle)) return const id: FeedIdOrInboxHandle = entry.inboxHandle || entry.feedId || "" + const isInbox = !!entry.inboxHandle const tx = createTransaction() tx.store(() => { @@ -200,11 +201,11 @@ class UnreadSyncService { tx.request(async () => { if (read) { await apiClient().reads.$post({ - json: { entryIds: [entryId] }, + json: { entryIds: [entryId], isInbox }, }) } else { await apiClient().reads.$delete({ - json: { entryId }, + json: { entryId, isInbox }, }) } })