From 4c560f1a031c21a3e735bdbad061b284a03b6618 Mon Sep 17 00:00:00 2001 From: kolaente Date: Thu, 21 Jul 2022 15:53:08 +0200 Subject: [PATCH] fix: don't try to load lists after logging out Resolves https://kolaente.dev/vikunja/frontend/issues/329 --- src/views/Home.vue | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/views/Home.vue b/src/views/Home.vue index ac82f261..92110b66 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -76,12 +76,16 @@ const welcome = useDateTimeSalutation() const store = useStore() const listHistory = computed(() => { + // If we don't check this, it tries to load the list background right after logging out + if(!store.state.auth.authenticated) { + return [] + } + return getHistory() .map(l => store.getters['lists/getListById'](l.id)) .filter(l => l !== null) }) - const migratorsEnabled = computed(() => store.state.config.availableMigrators?.length > 0) const userInfo = computed(() => store.state.auth.info) const hasTasks = computed(() => store.state.hasTasks)