From 15da3462ac72bbed68120cc7b7b63abe6253dabf Mon Sep 17 00:00:00 2001 From: Lukas Hirt Date: Wed, 9 Sep 2020 13:01:22 +0200 Subject: [PATCH] Use payload when inserting created account --- ui/components/accounts/AccountsListNewAccountRow.vue | 1 + ui/store/index.js | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/components/accounts/AccountsListNewAccountRow.vue b/ui/components/accounts/AccountsListNewAccountRow.vue index 2039c14654..ab8957004c 100644 --- a/ui/components/accounts/AccountsListNewAccountRow.vue +++ b/ui/components/accounts/AccountsListNewAccountRow.vue @@ -79,6 +79,7 @@ export default { } this.createNewAccount({ username: this.username, email: this.email, password: this.password }) + this.emitCancel() }, checkUsername () { diff --git a/ui/store/index.js b/ui/store/index.js index c94e74ba82..3dde6ebd13 100644 --- a/ui/store/index.js +++ b/ui/store/index.js @@ -189,8 +189,7 @@ const actions = { }) if (response.status === 201) { - commit('PUSH_NEW_ACCOUNT', account) - console.log(response) + commit('PUSH_NEW_ACCOUNT', response.data) } else { dispatch('showMessage', { title: 'Failed to create account',