diff --git a/src/domain/session/leftpanel/PlaceholderRoomTileViewModel.js b/src/domain/session/leftpanel/PlaceholderRoomTileViewModel.js index 5a6db640..b4ae62a5 100644 --- a/src/domain/session/leftpanel/PlaceholderRoomTileViewModel.js +++ b/src/domain/session/leftpanel/PlaceholderRoomTileViewModel.js @@ -36,6 +36,7 @@ export class PlaceholderRoomTileViewModel extends BaseTileViewModel { } compare(other) { + // TODO: factor this out with the compare(other) of the room tile as it does this check as well. if (other._room.index !== undefined) { return this._room.index > other._room.index ? 1 : -1; } diff --git a/src/domain/session/leftpanel/RoomTileViewModel.js b/src/domain/session/leftpanel/RoomTileViewModel.js index 51b3fdf0..db380f5d 100644 --- a/src/domain/session/leftpanel/RoomTileViewModel.js +++ b/src/domain/session/leftpanel/RoomTileViewModel.js @@ -41,7 +41,7 @@ export class RoomTileViewModel extends BaseTileViewModel { // sync v3 has its own ordering, use it if we have an index if (this._room.index !== undefined && other._room.index !== undefined) { - return this._room.index > other._room.index ? 1 : -1;; + return this._room.index > other._room.index ? 1 : -1; } /* diff --git a/src/matrix/Session.js b/src/matrix/Session.js index 217de25e..37fd90ad 100644 --- a/src/matrix/Session.js +++ b/src/matrix/Session.js @@ -401,7 +401,6 @@ export class Session { room.setInvite(invite); } } - this._rooms.add(room.id, room); } dispose() {