Fix JS error when logging in with bad credentials

This commit is contained in:
Florian Dupret 2021-04-30 08:26:05 +02:00
commit e222d0ca56

View file

@ -98,11 +98,10 @@ export default {
this.clear(); this.clear();
this.$store.commit("setToken", response.data.access_token); this.$store.commit("setToken", response.data.access_token);
this.$emit("logged-in"); this.$emit("logged-in");
let user = await api.users.self();
this.$store.commit("setUserData", user);
} }
let user = await api.users.self();
this.$store.commit("setUserData", user);
this.loading = false; this.loading = false;
}, },
}, },