From 0df4b724ca9d514ab820031ab7ba02efb4d88b41 Mon Sep 17 00:00:00 2001 From: Nolan Lawson Date: Sat, 13 Nov 2021 10:57:36 -0800 Subject: [PATCH] fix: fix for when notification is undefined (#2093) --- src/routes/_database/timelines/fetchNotification.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/routes/_database/timelines/fetchNotification.js b/src/routes/_database/timelines/fetchNotification.js index 93b35ab4..39888166 100644 --- a/src/routes/_database/timelines/fetchNotification.js +++ b/src/routes/_database/timelines/fetchNotification.js @@ -6,6 +6,9 @@ export function fetchNotification (notificationsStore, statusesStore, accountsSt notificationsStore.get(id).onsuccess = e => { const notification = e.target.result callback(notification) + if (!notification) { + return + } fetchAccount(accountsStore, notification[ACCOUNT_ID], account => { notification.account = account })