From fb1a86712df2c85cfd523bb814abe85a0c3eae9a Mon Sep 17 00:00:00 2001 From: isUnknown Date: Wed, 8 Oct 2025 15:01:08 +0200 Subject: [PATCH] assign default value for projects --- src/stores/projects.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/stores/projects.js b/src/stores/projects.js index 5f7ff94..25c5a2f 100644 --- a/src/stores/projects.js +++ b/src/stores/projects.js @@ -9,8 +9,8 @@ export const useProjectsStore = defineStore('projects', () => { const currentProjects = computed(() => { return ( projects.value - .filter((project) => project.status === 'listed') - .sort((a, b) => new Date(b.modified) - new Date(a.modified)) || [] + ?.filter((project) => project.status === 'listed') + .sort((a, b) => new Date(b.modified) - new Date(a.modified)) ?? [] ); });