From 332354e5b68595855dde02d7efb64cd696589efe Mon Sep 17 00:00:00 2001 From: David Baker Date: Wed, 2 Mar 2016 14:23:20 +0000 Subject: [PATCH] Uncommit 71cb04c50ad1b76ac02d537cd096889ecdcc9f0a (I failed to branch) --- src/components/structures/RoomDirectory.js | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/src/components/structures/RoomDirectory.js b/src/components/structures/RoomDirectory.js index 3fecd3f68e..6cc90f7968 100644 --- a/src/components/structures/RoomDirectory.js +++ b/src/components/structures/RoomDirectory.js @@ -66,27 +66,9 @@ module.exports = React.createClass({ }, showRoom: function(roomId) { - var room; - for (var i = 0; i < this.state.publicRooms.length; ++i) { - if (this.state.publicRooms[i].room_id == roomId) { - room = this.state.publicRooms[i]; - break; - } - } - var oob_data = {}; - if (room) { - oob_data = { - avatarUrl: room.avatar_url, - // XXX: This logic is duplicated from the JS SDK which - // would normally decide what the name is. - name: room.name || room.aliases[0], - }; - } - dis.dispatch({ action: 'view_room', - room_id: roomId, - oob_data: oob_data, + room_id: roomId }); },