From a407de7c4e2d32923b58bd626120fba442eb9f87 Mon Sep 17 00:00:00 2001 From: Muhammad Salman Date: Fri, 12 Jul 2024 20:28:55 +0500 Subject: [PATCH] fix[#75]: page going blank when searching non existing articles --- src/App.vue | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/App.vue b/src/App.vue index c9352cb..e26ae13 100644 --- a/src/App.vue +++ b/src/App.vue @@ -144,7 +144,11 @@ export default defineComponent({ try { // @ts-ignore const response = await this.$chronosAPI.searchArticles(this.chronosStore.prefLang, this.search, this.collectionShortName); - this.searchResponse = response; + if (response != null) { + this.searchResponse = response; + } else { + this.searchResponse = []; + } } catch (error) { console.error("Error searching articles:", error); this.searchResponse = [];