From d9e44f88fcad828664590ce88c67deff36f104a3 Mon Sep 17 00:00:00 2001 From: David Manthey Date: Tue, 10 Dec 2024 08:37:26 -0500 Subject: [PATCH] Guard the list items height check --- client/src/components/FileBrowser.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/components/FileBrowser.vue b/client/src/components/FileBrowser.vue index 4a4d2000..9e742fef 100644 --- a/client/src/components/FileBrowser.vue +++ b/client/src/components/FileBrowser.vue @@ -89,7 +89,7 @@ const calculateVisibleItems = () => { const listHeight = ref(0); const visibleItems = ref(0); // Determine the height of each list item - const listItemHeight = listItems ? listItems[0].clientHeight : 0; + const listItemHeight = listItems && listItems[0] ? listItems[0].clientHeight : 0; directoryData.value.childrenImages.forEach(() => { listHeight.value += listItemHeight;