From 7f4b5513ee38710a134b41d9ece8efd2b7b7dd3b Mon Sep 17 00:00:00 2001 From: Maksim Sukharev Date: Tue, 28 May 2024 15:03:28 +0200 Subject: [PATCH] fix(NewConversationDialog): get participants list before join Signed-off-by: Maksim Sukharev --- .../NewConversationDialog/NewConversationDialog.vue | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/components/NewConversationDialog/NewConversationDialog.vue b/src/components/NewConversationDialog/NewConversationDialog.vue index 57ddcc2056b..9400a278f78 100644 --- a/src/components/NewConversationDialog/NewConversationDialog.vue +++ b/src/components/NewConversationDialog/NewConversationDialog.vue @@ -333,7 +333,11 @@ export default { if (!this.isInCall) { // Push the newly created conversation's route. - this.pushNewRoute() + this.$router.push({ name: 'conversation', params: { token: this.newConversation.token } }) + .catch(err => console.debug(`Error while pushing the new conversation's route: ${err}`)) + + // Get complete participant list in advance + this.$store.dispatch('fetchParticipants', { token: this.newConversation.token }) } // Close the modal right away if the conversation is public. @@ -342,11 +346,6 @@ export default { } }, - pushNewRoute() { - this.$router.push({ name: 'conversation', params: { token: this.newConversation.token } }) - .catch(err => console.debug(`Error while pushing the new conversation's route: ${err}`)) - }, - /** Handles the press of the enter key */ handleEnter() { if (!this.disabled) {