Delete pending session store and states after session is created.
This commit is contained in:
parent
1f4a360a0c
commit
3877b2f58e
|
@ -17,6 +17,7 @@ Improvements 🙌:
|
|||
Bugfix 🐛:
|
||||
- Improve support for image/audio/video/file selection with intent changes (#1376)
|
||||
- Fix Splash layout on small screens
|
||||
- Invalid popup when pressing back (#1635)
|
||||
|
||||
Translations 🗣:
|
||||
-
|
||||
|
|
|
@ -419,11 +419,16 @@ class LoginViewModel @AssistedInject constructor(
|
|||
loginConfig = action.loginConfig
|
||||
|
||||
// If there is a pending email validation continue on this step
|
||||
try {
|
||||
if (registrationWizard?.isRegistrationStarted == true) {
|
||||
currentThreePid?.let {
|
||||
if (isRegistrationStarted) {
|
||||
handle(LoginAction.PostViewEvent(LoginViewEvents.OnSendEmailSuccess(it)))
|
||||
}
|
||||
}
|
||||
} catch (e: Throwable) {
|
||||
// NOOP. API is designed to use wizards in a login/registration flow,
|
||||
// but we need to check the state anyway.
|
||||
}
|
||||
}
|
||||
|
||||
private fun handleResetPassword(action: LoginAction.ResetPassword) {
|
||||
|
@ -679,6 +684,7 @@ class LoginViewModel @AssistedInject constructor(
|
|||
|
||||
private fun onSessionCreated(session: Session) {
|
||||
activeSessionHolder.setActiveSession(session)
|
||||
authenticationService.reset()
|
||||
session.configureAndStart(applicationContext)
|
||||
setState {
|
||||
copy(
|
||||
|
|
Loading…
Reference in New Issue