MM-10722 Fix display name of other user after joining a channel (#1709)
* fix bundling failed with "mime-db" error Signed-off-by: Saturnino Abril <saturnino.abril@gmail.com> * fix display name of other user after joining a channel Signed-off-by: Saturnino Abril <saturnino.abril@gmail.com>
This commit is contained in:
parent
cd3da28e1f
commit
b500df868e
1 changed files with 9 additions and 6 deletions
|
|
@ -179,14 +179,17 @@ export default class CombinedSystemMessage extends React.PureComponent {
|
|||
}
|
||||
|
||||
componentDidMount() {
|
||||
this.loadUserProfiles();
|
||||
this.loadUserProfiles(this.props.allUserIds);
|
||||
}
|
||||
|
||||
loadUserProfiles = async () => {
|
||||
const {
|
||||
actions,
|
||||
allUserIds,
|
||||
} = this.props;
|
||||
componentWillReceiveProps(nextProps) {
|
||||
if (this.props.allUserIds !== nextProps.allUserIds) {
|
||||
this.loadUserProfiles(nextProps.allUserIds);
|
||||
}
|
||||
}
|
||||
|
||||
loadUserProfiles = async (allUserIds) => {
|
||||
const {actions} = this.props;
|
||||
const {data: userProfiles} = await actions.getProfilesByIds(allUserIds);
|
||||
|
||||
this.setState({userProfiles});
|
||||
|
|
|
|||
Loading…
Reference in a new issue