From 1cf5ddc4350e98189840d462d3e6545f3594b0c0 Mon Sep 17 00:00:00 2001 From: charles Date: Sun, 24 Dec 2023 22:04:53 -0600 Subject: [PATCH] Pack check fails if data.creatures isnt an array. --- src/summon/menu/SummoningMenu.svelte | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/summon/menu/SummoningMenu.svelte b/src/summon/menu/SummoningMenu.svelte index b10ad1a..ee295be 100644 --- a/src/summon/menu/SummoningMenu.svelte +++ b/src/summon/menu/SummoningMenu.svelte @@ -43,7 +43,7 @@ data.creatures = loadPacks(); } else if (data.creatures instanceof CompendiumCollection) { data.creatures = loadPacks(false, false, [data.creatures.metadata]); - } else if (data.creatures.some((pack) => pack instanceof CompendiumCollection)) { + } else if (data.creatures.some && data.creatures.some((pack) => pack instanceof CompendiumCollection)) { data.creatures = new Promise((resolveOuter) => { data.creatures = data.creatures.map(async (pack) => { if (pack instanceof CompendiumCollection) {