1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-12-08 17:48:33 +03:00

Fix RoomViewStore forgetting some details of a view room call (#7512)

This commit is contained in:
Michael Telatynski
2022-01-12 20:12:28 +00:00
committed by GitHub
parent 3a18fd8f71
commit ec6c1b8272
21 changed files with 67 additions and 57 deletions

View File

@@ -834,7 +834,7 @@ export default class SpaceRoomView extends React.PureComponent<IProps, IState> {
};
private onAction = (payload: ActionPayload) => {
if (payload.action === "view_room" && payload.room_id === this.props.space.roomId) {
if (payload.action === Action.ViewRoom && payload.room_id === this.props.space.roomId) {
this.setState({ phase: Phase.Landing });
return;
}
@@ -862,7 +862,7 @@ export default class SpaceRoomView extends React.PureComponent<IProps, IState> {
private goToFirstRoom = async () => {
if (this.state.firstRoomId) {
defaultDispatcher.dispatch({
action: "view_room",
action: Action.ViewRoom,
room_id: this.state.firstRoomId,
});
return;