Revert deletion of hydrateSession (#29703)
* Revert deletion of hydrateSession * remove line break to make prettier happy :-) * add tests for hydrateSession on soft logout * fix coding style --------- Co-authored-by: Florian Duros <florianduros@element.io>
This commit is contained in:
@@ -168,7 +168,7 @@ export default class SoftLogout extends React.Component<IProps, IState> {
|
||||
return;
|
||||
}
|
||||
|
||||
Lifecycle.setLoggedIn(credentials).catch((e) => {
|
||||
Lifecycle.hydrateSession(credentials).catch((e) => {
|
||||
logger.error(e);
|
||||
this.setState({ busy: false, errorText: _t("auth|failed_soft_logout_auth") });
|
||||
});
|
||||
@@ -204,7 +204,7 @@ export default class SoftLogout extends React.Component<IProps, IState> {
|
||||
return false;
|
||||
}
|
||||
|
||||
return Lifecycle.setLoggedIn(credentials)
|
||||
return Lifecycle.hydrateSession(credentials)
|
||||
.then(() => {
|
||||
if (this.props.onTokenLoginCompleted) {
|
||||
this.props.onTokenLoginCompleted();
|
||||
|
||||
Reference in New Issue
Block a user