From 966d57dfa2a162ef9d50d0152bfd02fe9c91fdcf Mon Sep 17 00:00:00 2001 From: kashaf-ansari-dev Date: Fri, 31 Jul 2026 18:04:59 +0500 Subject: [PATCH] mobile: allow opening empty trashed notes without contentId Signed-off-by: kashaf-ansari-dev --- apps/mobile/app/components/list-items/note/wrapper.tsx | 6 +++--- apps/mobile/app/components/note-history/preview.tsx | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/mobile/app/components/list-items/note/wrapper.tsx b/apps/mobile/app/components/list-items/note/wrapper.tsx index fc649365e..3ea524653 100644 --- a/apps/mobile/app/components/list-items/note/wrapper.tsx +++ b/apps/mobile/app/components/list-items/note/wrapper.tsx @@ -58,9 +58,9 @@ export const openNote = async ( } if (isTrash) { - if (!note.contentId) return; - - const content = await db.content.get(note.contentId as string); + const content = note.contentId + ? await db.content.get(note.contentId) + : undefined; presentSheet({ component: }); diff --git a/apps/mobile/app/components/note-history/preview.tsx b/apps/mobile/app/components/note-history/preview.tsx index a92afc887..b2a7f4510 100644 --- a/apps/mobile/app/components/note-history/preview.tsx +++ b/apps/mobile/app/components/note-history/preview.tsx @@ -198,7 +198,7 @@ export default function NotePreview({