From 7695949bd7ba315ab5e17a1e816b843bb6e10439 Mon Sep 17 00:00:00 2001 From: Troplo Date: Sat, 30 Jul 2022 22:11:34 +1000 Subject: [PATCH] Update Header.vue --- frontend/src/components/Header.vue | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/frontend/src/components/Header.vue b/frontend/src/components/Header.vue index b77646e..5336cf6 100644 --- a/frontend/src/components/Header.vue +++ b/frontend/src/components/Header.vue @@ -797,7 +797,6 @@ export default { ) this.settings.addMembers.dialog = false this.settings.addMembers.users = [] - this.settings.addMembers.results = [] }) .catch((e) => { AjaxErrorHandler(this.$store)(e) @@ -931,14 +930,12 @@ export default { this.axios .get("/api/v1/communications/search?query=") .then((res) => { - if (this.settings.item) { - this.settings.addMembers.results = res.data - this.settings.addMembers.results = - this.settings.addMembers.results.filter( - (user) => - !this.settings.item.chat.users.find((u) => u.id === user.id) - ) - } + this.settings.addMembers.results = res.data + this.settings.addMembers.results = + this.settings.addMembers.results.filter( + (user) => + !this.settings.item.chat.users.find((u) => u.id === user.id) + ) }) .catch(() => {}) }