You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-20 16:22:28 +03:00
fix NPE when getGroupProfiles returns null
This commit is contained in:
@@ -107,7 +107,11 @@ export default class Flair extends React.Component {
|
|||||||
}
|
}
|
||||||
const profiles = await this._getGroupProfiles(groups);
|
const profiles = await this._getGroupProfiles(groups);
|
||||||
if (!this.unmounted) {
|
if (!this.unmounted) {
|
||||||
this.setState({profiles: profiles.filter((profile) => {return profile.avatarUrl;})});
|
this.setState({
|
||||||
|
profiles: profiles.filter((profile) => {
|
||||||
|
return profile ? profile.avatarUrl : false;
|
||||||
|
})
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user