From 9c632510215ec88dfef98b6bc21e4559bf72b69d Mon Sep 17 00:00:00 2001 From: thecodrr Date: Tue, 19 Apr 2022 17:22:06 +0500 Subject: [PATCH] fix: app crash on opening version history (fixes streetwriters/notesnook#524) --- apps/web/src/components/editor/header.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/web/src/components/editor/header.js b/apps/web/src/components/editor/header.js index 200637bc9..7279b9e00 100644 --- a/apps/web/src/components/editor/header.js +++ b/apps/web/src/components/editor/header.js @@ -15,7 +15,7 @@ function Header({ readonly }) { const setTag = useStore((store) => store.setTag); const setTitle = useStore((store) => store.setTitle); const filterableTags = useMemo(() => { - return db.tags.all.filter((t) => tags.every((tag) => tag !== t.title)); + return db.tags.all.filter((t) => tags?.every((tag) => tag !== t?.title)); }, [tags]); return (