diff --git a/app/containers/UIKit/MultiSelect/Items.tsx b/app/containers/UIKit/MultiSelect/Items.tsx index 4e9265d24..311894db1 100644 --- a/app/containers/UIKit/MultiSelect/Items.tsx +++ b/app/containers/UIKit/MultiSelect/Items.tsx @@ -28,7 +28,7 @@ const keyExtractor = (item: IItemData) => item.value.toString(); // RectButton doesn't work on modal (Android) const Item = ({ item, selected, onSelect, theme }: IItem) => { - const itemName = item.value || item.text.text.toLowerCase(); + const itemName = item.value?.name || item.text.text.toLowerCase(); return ( ({ - value: channel.name || channel.fname, + value: channel, text: { text: RocketChat.getRoomTitle(channel) }, imageUrl: getAvatar(channel) }))} diff --git a/app/views/CreateDiscussionView/index.tsx b/app/views/CreateDiscussionView/index.tsx index 67e467b27..2810daaa2 100644 --- a/app/views/CreateDiscussionView/index.tsx +++ b/app/views/CreateDiscussionView/index.tsx @@ -137,8 +137,6 @@ class CreateChannelView extends React.Component { get isEncryptionEnabled() { const { channel } = this.state; const { encryptionEnabled } = this.props; - // TODO: remove this ts-ignore when migrate the file: app/lib/encryption/constants.js - // @ts-ignore return encryptionEnabled && E2E_ROOM_TYPES[channel?.t]; }