From 9396a5ebcc5188f46c9e1edcba5df0f11fe4a3f3 Mon Sep 17 00:00:00 2001 From: Jack Date: Fri, 16 Jul 2021 16:09:20 +0100 Subject: [PATCH] fixed #1625 --- src/js/commandline-lists.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/js/commandline-lists.js b/src/js/commandline-lists.js index 554e851ba..1a9cd9af9 100644 --- a/src/js/commandline-lists.js +++ b/src/js/commandline-lists.js @@ -201,7 +201,7 @@ let commandsTags = { }; export function updateTagCommands() { - if (DB.getSnapshot().tags.length > 0) { + if (DB.getSnapshot()?.tags?.length > 0) { commandsTags.list = []; commandsTags.list.push({ @@ -266,7 +266,7 @@ let commandsPresets = { }; export function updatePresetCommands() { - if (DB.getSnapshot().presets.length > 0) { + if (DB.getSnapshot()?.presets?.length > 0) { commandsPresets.list = []; DB.getSnapshot().presets.forEach((preset) => {