From 942659df0dbe5754f53fe6084af4302d3ae0ff4f Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 4 Nov 2015 14:15:57 +0000 Subject: [PATCH] Work around the bug where some channels have no name from the js sdk which was causing vector to exception and never load. --- src/skins/vector/views/molecules/RoomTile.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/skins/vector/views/molecules/RoomTile.js b/src/skins/vector/views/molecules/RoomTile.js index 82616b5a59..ece4804321 100644 --- a/src/skins/vector/views/molecules/RoomTile.js +++ b/src/skins/vector/views/molecules/RoomTile.js @@ -56,7 +56,8 @@ module.exports = React.createClass({ name = this.props.room.getMember(MatrixClientPeg.get().credentials.userId).events.member.getSender(); } else { - name = this.props.room.name; + // XXX: We should never display raw room IDs, but sometimes the room name js sdk gives is undefined + name = this.props.room.name || this.props.room.roomId; } name = name.replace(":", ":\u200b"); // add a zero-width space to allow linewrapping after the colon