From 11061e1965bff4e976897f6a01b75ae004dd7b72 Mon Sep 17 00:00:00 2001 From: Jonas Sulzer Date: Wed, 26 Jun 2019 14:43:52 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20FIX:=20displaying=20of=20exact?= =?UTF-8?q?=20alias=20maches?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Jonas Sulzer --- src/components/Search.vue | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/components/Search.vue b/src/components/Search.vue index a425b3b7..7b425f83 100644 --- a/src/components/Search.vue +++ b/src/components/Search.vue @@ -106,6 +106,9 @@ export default { computed: { allResults() { if (this.results.accounts) { + if (this.results.accounts.exact) { + return [this.results.accounts.exact] + } return this.results.accounts.result } return [] @@ -139,6 +142,9 @@ export default { this.results = response.data.result this.loading = false + if (this.results.accounts.exact !== null) { + this.$store.commit('addAccount', { actorId: this.results.accounts.exact.id, data: this.results.accounts.exact }) + } this.results.accounts.result.forEach((account) => { this.$store.commit('addAccount', { actorId: account.id, data: account }) })