mirror of https://github.com/vector-im/riot-web
Merge pull request #3566 from matrix-org/t3chguy/sort_crash
LifeCycle onLoggedOut unmount before stopping clientpull/21833/head
commit
814917d9ed
|
@ -610,7 +610,7 @@ export function onLoggedOut() {
|
||||||
// Ensure that we dispatch a view change **before** stopping the client so
|
// Ensure that we dispatch a view change **before** stopping the client so
|
||||||
// so that React components unmount first. This avoids React soft crashes
|
// so that React components unmount first. This avoids React soft crashes
|
||||||
// that can occur when components try to use a null client.
|
// that can occur when components try to use a null client.
|
||||||
dis.dispatch({action: 'on_logged_out'});
|
dis.dispatch({action: 'on_logged_out'}, true);
|
||||||
stopMatrixClient();
|
stopMatrixClient();
|
||||||
_clearStorage().done();
|
_clearStorage().done();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue