Redirect to the registration page if there's a 3PID invite
Fixes https://github.com/vector-im/element-web/issues/15130pull/21833/head
parent
dc44b9ef59
commit
b1cdf1bc9a
|
@ -413,9 +413,13 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> {
|
||||||
});
|
});
|
||||||
}).then((loadedSession) => {
|
}).then((loadedSession) => {
|
||||||
if (!loadedSession) {
|
if (!loadedSession) {
|
||||||
// fall back to showing the welcome screen
|
// fall back to showing the welcome screen... unless we have a 3pid invite pending
|
||||||
|
if (ThreepidInviteStore.instance.pickBestInvite()) {
|
||||||
|
dis.dispatch({action: 'start_registration'});
|
||||||
|
} else {
|
||||||
dis.dispatch({action: "view_welcome_page"});
|
dis.dispatch({action: "view_welcome_page"});
|
||||||
}
|
}
|
||||||
|
}
|
||||||
});
|
});
|
||||||
// Note we don't catch errors from this: we catch everything within
|
// Note we don't catch errors from this: we catch everything within
|
||||||
// loadSession as there's logic there to ask the user if they want
|
// loadSession as there's logic there to ask the user if they want
|
||||||
|
|
Loading…
Reference in New Issue