aboutsummaryrefslogtreecommitdiff
path: root/src/components/user_profile/user_profile.js
diff options
context:
space:
mode:
authorshpuld <shp@cock.li>2017-11-17 02:17:47 +0200
committershpuld <shp@cock.li>2017-11-17 02:17:47 +0200
commite13c8c3fd292e5afa43f78bfff9e1bdd754c1df9 (patch)
tree5dc86bd35d39479cf8ab96bfe1379adce033843e /src/components/user_profile/user_profile.js
parent44073e72fdb5d253f48b6f0bb0755da89f7e4ae1 (diff)
parent86e685ac3452e42c3276e6ea2d3e7988abf2941a (diff)
Merge branch 'develop' of git.pleroma.social:pleroma/pleroma-fe into feature/custom-theme
Diffstat (limited to 'src/components/user_profile/user_profile.js')
-rw-r--r--src/components/user_profile/user_profile.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/components/user_profile/user_profile.js b/src/components/user_profile/user_profile.js
index 48a8a073..26be1801 100644
--- a/src/components/user_profile/user_profile.js
+++ b/src/components/user_profile/user_profile.js
@@ -5,6 +5,9 @@ const UserProfile = {
created () {
this.$store.commit('clearTimeline', { timeline: 'user' })
this.$store.dispatch('startFetching', ['user', this.userId])
+ if (!this.$store.state.users.usersObject[this.userId]) {
+ this.$store.dispatch('fetchUser', this.userId)
+ }
},
destroyed () {
this.$store.dispatch('stopFetching', 'user')
@@ -18,7 +21,7 @@ const UserProfile = {
if (this.timeline.statuses[0]) {
return this.timeline.statuses[0].user
} else {
- return false
+ return this.$store.state.users.usersObject[this.userId] || false
}
}
},