mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2024-12-27 11:28:33 +03:00
Adds error throw for LoginActivity LoginMode Unknown
This commit is contained in:
parent
a173accfa5
commit
ef59faf160
2 changed files with 165 additions and 163 deletions
|
@ -67,9 +67,11 @@ internal class DefaultRegistrationWizard(
|
|||
return performRegistrationRequest(params, LoginType.PASSWORD)
|
||||
}
|
||||
|
||||
override suspend fun createAccount(userName: String?,
|
||||
override suspend fun createAccount(
|
||||
userName: String?,
|
||||
password: String?,
|
||||
initialDeviceDisplayName: String?): RegistrationResult {
|
||||
initialDeviceDisplayName: String?
|
||||
): RegistrationResult {
|
||||
val params = RegistrationParams(
|
||||
username = userName,
|
||||
password = password,
|
||||
|
|
|
@ -252,7 +252,7 @@ open class LoginActivity : VectorBaseActivity<ActivityLoginBinding>(), UnlockedA
|
|||
SignMode.SignIn -> {
|
||||
// It depends on the LoginMode
|
||||
when (state.loginMode) {
|
||||
LoginMode.Unknown,
|
||||
LoginMode.Unknown -> error("Developer error")
|
||||
is LoginMode.Sso -> launchSsoFlow()
|
||||
is LoginMode.SsoAndPassword,
|
||||
LoginMode.Password -> addFragmentToBackstack(views.loginFragmentContainer,
|
||||
|
|
Loading…
Reference in a new issue