From 89bcb549cc88a60ef64eaf35f21dc729758f7ac8 Mon Sep 17 00:00:00 2001 From: Kavin <20838718+FireMasterK@users.noreply.github.com> Date: Sat, 2 Jul 2022 13:34:45 +0100 Subject: [PATCH] Use opensearch for suggestions api. --- src/components/SearchSuggestions.vue | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/components/SearchSuggestions.vue b/src/components/SearchSuggestions.vue index 3e0455a1..99517898 100644 --- a/src/components/SearchSuggestions.vue +++ b/src/components/SearchSuggestions.vue @@ -47,9 +47,11 @@ export default { } }, async refreshSuggestions() { - this.searchSuggestions = await this.fetchJson(this.apiUrl() + "/suggestions", { - query: this.searchText, - }); + this.searchSuggestions = ( + await this.fetchJson(this.apiUrl() + "/opensearch/suggestions", { + query: this.searchText, + }) + )?.[1]; this.searchSuggestions.unshift(this.searchText); this.setSelected(0); },