Improve SSO UIA

Fixes Fallback UIA postmessage interface
Auto-closes SSO UIA tab when the user has completed the flow within it
Error for when auth stage is restarted because it failed
This commit is contained in:
Michael Telatynski 2021-01-28 10:45:29 +00:00
parent 34ae766893
commit 1761a4ec80
4 changed files with 62 additions and 9 deletions

View file

@ -325,9 +325,13 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> {
this.props.realQueryParams,
this.props.defaultDeviceDisplayName,
).then(async (loggedIn) => {
if (this.props.realQueryParams?.loginToken) {
// remove the loginToken from the URL regardless
this.props.onTokenLoginCompleted();
}
if (loggedIn) {
this.tokenLogin = true;
this.props.onTokenLoginCompleted();
// Create and start the client
await Lifecycle.restoreFromLocalStorage({