mirror of
https://github.com/element-hq/element-web
synced 2024-11-28 12:28:50 +03:00
Redirect to the registration page if there's a 3PID invite
Fixes https://github.com/vector-im/element-web/issues/15130
This commit is contained in:
parent
dc44b9ef59
commit
b1cdf1bc9a
1 changed files with 6 additions and 2 deletions
|
@ -413,8 +413,12 @@ export default class MatrixChat extends React.PureComponent<IProps, IState> {
|
|||
});
|
||||
}).then((loadedSession) => {
|
||||
if (!loadedSession) {
|
||||
// fall back to showing the welcome screen
|
||||
dis.dispatch({action: "view_welcome_page"});
|
||||
// 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"});
|
||||
}
|
||||
}
|
||||
});
|
||||
// Note we don't catch errors from this: we catch everything within
|
||||
|
|
Loading…
Reference in a new issue