small fixes

This commit is contained in:
Bruno Windels 2022-03-25 14:43:22 +01:00
parent eaf92b382b
commit 4bf171def9
4 changed files with 4 additions and 4 deletions

View file

@ -191,7 +191,7 @@ export class SessionViewModel extends ViewModel {
async _createArchivedRoomViewModel(roomId) { async _createArchivedRoomViewModel(roomId) {
const room = await this._client.session.loadArchivedRoom(roomId); const room = await this._client.session.loadArchivedRoom(roomId);
if (room) { if (room) {
const roomVM = new RoomViewModel(this.childOptions({room})); const roomVM = new RoomViewModel(this.childOptions({room, session: this._client.session}));
roomVM.load(); roomVM.load();
return roomVM; return roomVM;
} }

View file

@ -62,7 +62,7 @@ export class PickMapObservableValue<K, V> extends BaseObservableValue<V | undefi
this.key = undefined; this.key = undefined;
// try to see if there is another key that fullfills pickKey // try to see if there is another key that fullfills pickKey
for (const [key] of this.map) { for (const [key] of this.map) {
this.updateKey(key) || changed; this.updateKey(key);
} }
this.emit(this.get()); this.emit(this.get());
} }

View file

@ -53,6 +53,6 @@ export function viewClassForEntry(entry: SimpleTile): TileViewConstructor | unde
case "redacted": case "redacted":
return RedactedView; return RedactedView;
case "call": case "call":
return CallTileView; return CallTileView as any as TileViewConstructor;
} }
} }