Commit 22899f31 authored by Djorkaeff Alexandre's avatar Djorkaeff Alexandre Committed by Diego Mello
Browse files

[FIX] Avatar shown when useRealName is activated (#1162)

* Fix avatar when use real name

* Wrong indentation
parent fdc5114a
......@@ -63,8 +63,9 @@ class RoomItem extends React.Component {
status: PropTypes.string,
toggleFav: PropTypes.func,
toggleRead: PropTypes.func,
hideChannel: PropTypes.func
};
hideChannel: PropTypes.func,
avatar: PropTypes.bool
}
static defaultProps = {
avatarSize: 48
......@@ -217,7 +218,7 @@ class RoomItem extends React.Component {
render() {
const {
unread, userMentions, name, _updatedAt, alert, testID, type, avatarSize, baseUrl, userId, username, token, id, prid, showLastMessage, lastMessage, isRead, width, favorite, status
unread, userMentions, name, _updatedAt, alert, testID, type, avatarSize, baseUrl, userId, username, token, id, prid, showLastMessage, lastMessage, isRead, width, favorite, status, avatar
} = this.props;
const date = formatDate(_updatedAt);
......@@ -274,7 +275,7 @@ class RoomItem extends React.Component {
accessibilityLabel={accessibilityLabel}
>
<Avatar
text={name}
text={avatar}
size={avatarSize}
type={type}
baseUrl={baseUrl}
......
......@@ -603,6 +603,7 @@ class RoomsListView extends React.Component {
userMentions={item.userMentions}
isRead={this.getIsRead(item)}
favorite={item.f}
avatar={item.name}
lastMessage={item.lastMessage}
name={this.getRoomTitle(item)}
_updatedAt={item.roomUpdatedAt}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment