Merge pull request #1412 from mattermost/plt-1089
PLT-1089 Fix profile not loading in RHS on refresh
Этот коммит содержится в:
@@ -29,7 +29,7 @@ export default class UserProfile extends React.Component {
|
|||||||
return {profile: {id: '0', username: '...'}};
|
return {profile: {id: '0', username: '...'}};
|
||||||
}
|
}
|
||||||
|
|
||||||
return {profile: profile};
|
return {profile};
|
||||||
}
|
}
|
||||||
componentDidMount() {
|
componentDidMount() {
|
||||||
UserStore.addChangeListener(this.onChange);
|
UserStore.addChangeListener(this.onChange);
|
||||||
|
|||||||
@@ -164,6 +164,10 @@ class UserStoreClass extends EventEmitter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
getProfile(userId) {
|
getProfile(userId) {
|
||||||
|
if (userId === this.getCurrentId()) {
|
||||||
|
return this.getCurrentUser();
|
||||||
|
}
|
||||||
|
|
||||||
return this.getProfiles()[userId];
|
return this.getProfiles()[userId];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user