Skip to content

Commit 3da1e43

Browse files
committed
fetch user data when going to settings
1 parent 0b0a9bd commit 3da1e43

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

frontend/src/views/app/Settings.vue

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,8 @@ export default {
276276
this.show = 'profile';
277277
}
278278
console.log(this.$store.getters.getLoggedInUser);
279+
const user = await this.$http.get(`/users/${this.$store.getters.getLoggedInUser.id}`);
280+
await this.$store.dispatch('login', user.data);
279281
const tags = this.$store.getters.getLoggedInUser.tags;
280282
for (let i = 0; i < tags.length; i += 1) {
281283
this.userInterests.push(tags[i].name);

0 commit comments

Comments
 (0)