From 5e26c1e1223d6a3fbe095f9344877f9d2403af3d Mon Sep 17 00:00:00 2001 From: dumbmoron Date: Tue, 23 Jul 2024 16:07:12 +0000 Subject: [PATCH] web/PickerItem: small refactor --- web/src/components/dialog/PickerItem.svelte | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/web/src/components/dialog/PickerItem.svelte b/web/src/components/dialog/PickerItem.svelte index 496801ed..379e2c66 100644 --- a/web/src/components/dialog/PickerItem.svelte +++ b/web/src/components/dialog/PickerItem.svelte @@ -14,17 +14,12 @@ let imageLoaded = false; - let itemType = item.type; - if (!itemType) { - itemType = "photo" - } + $: itemType = item.type ?? "photo";