Skip to content

Commit 5835ea0

Browse files
committed
Only display rooms you're currently joined to in recents
1 parent 5fb6ea9 commit 5835ea0

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

‎src/controllers/organisms/RoomList.js‎

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,14 @@ module.exports = {
9696
},
9797

9898
getRoomList: function() {
99-
return RoomListSorter.mostRecentActivityFirst(MatrixClientPeg.get().getRooms());
99+
return RoomListSorter.mostRecentActivityFirst(
100+
MatrixClientPeg.get().getRooms().filter(function(room) {
101+
return room.hasMembershipState(
102+
MatrixClientPeg.get().credentials.userId,
103+
"join"
104+
);
105+
})
106+
);
100107
},
101108

102109
makeRoomTiles: function() {

0 commit comments

Comments
 (0)