From b42968b4d7d3aab1139ab22995c321251751e405 Mon Sep 17 00:00:00 2001 From: rchrist Date: Thu, 6 Jun 2019 21:27:12 +0200 Subject: [PATCH] bugfix --- .../frontend/src/pages/Profile.vue | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/labswp_2019_sose_geocaching_frontend/frontend/src/pages/Profile.vue b/labswp_2019_sose_geocaching_frontend/frontend/src/pages/Profile.vue index a7b627d..9e19de5 100644 --- a/labswp_2019_sose_geocaching_frontend/frontend/src/pages/Profile.vue +++ b/labswp_2019_sose_geocaching_frontend/frontend/src/pages/Profile.vue @@ -534,19 +534,15 @@ this.updateStatus(); }, getUser() { - const data = { - "email" : this.newAdminMail - }; - JSON.stringify(data); const token = JSON.parse(localStorage.getItem('userToken')).token; - this.$axios.get(process.env.USER_API + '/account/email', data, { + this.$axios.get(process.env.USER_API + '/account/email/' + this.newAdminMail, { headers: { 'Authorization': 'Bearer ' + token, } }).then((response) => { let newAdminAccount = response.data; if (response.status === 200) { - this.confirmAddAdmin((JSON.parse(response).data)); + this.confirmAddAdmin(response.data); } }) .catch((error) => {