Fall back to MXID when no display name is present

MemberAvatar requires a display name, or else it refuses to render.

Signed-off-by: Robin Townsend <robin@robin.town>
pull/21833/head
Robin Townsend 2021-05-08 21:22:31 -04:00
parent 44b143c8c3
commit e46bc93178
1 changed files with 1 additions and 1 deletions

View File

@ -101,7 +101,7 @@ export default class EventTilePreview extends React.Component<IProps, IState> {
// Fake it more // Fake it more
event.sender = { event.sender = {
name: this.props.displayName, name: this.props.displayName || this.props.userId,
userId: this.props.userId, userId: this.props.userId,
getAvatarUrl: (..._) => { getAvatarUrl: (..._) => {
return Avatar.avatarUrlForUser( return Avatar.avatarUrlForUser(