mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2025-01-11 04:27:40 +01:00
refresh room view model when going from joined -> archived
given we have a dedicated class (ArchivedRoom) for it now
This commit is contained in:
parent
e3c1644d09
commit
82a1b37363
@ -61,12 +61,7 @@ export class RoomViewModelObservable extends ObservableValue {
|
|||||||
} else if (status.joined) {
|
} else if (status.joined) {
|
||||||
return this._sessionViewModel._createRoomViewModel(this.id);
|
return this._sessionViewModel._createRoomViewModel(this.id);
|
||||||
} else if (status.archived) {
|
} else if (status.archived) {
|
||||||
if (!this.get() || this.get().kind !== "room") {
|
|
||||||
return await this._sessionViewModel._createArchivedRoomViewModel(this.id);
|
return await this._sessionViewModel._createArchivedRoomViewModel(this.id);
|
||||||
} else {
|
|
||||||
// reuse existing Room
|
|
||||||
return this.get();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user