mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Fix profile loading in RHS on refresh
This commit is contained in:
@@ -29,7 +29,7 @@ export default class UserProfile extends React.Component {
|
||||
return {profile: {id: '0', username: '...'}};
|
||||
}
|
||||
|
||||
return {profile: profile};
|
||||
return {profile};
|
||||
}
|
||||
componentDidMount() {
|
||||
UserStore.addChangeListener(this.onChange);
|
||||
|
||||
@@ -164,6 +164,10 @@ class UserStoreClass extends EventEmitter {
|
||||
}
|
||||
|
||||
getProfile(userId) {
|
||||
if (userId === this.getCurrentId()) {
|
||||
return this.getCurrentUser();
|
||||
}
|
||||
|
||||
return this.getProfiles()[userId];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user