mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2025-02-02 20:26:47 +01:00
Code quality
This commit is contained in:
parent
bf5c1e9d8f
commit
ddb858380e
@ -109,4 +109,3 @@ internal class DefaultAddThreePidTask @Inject constructor(
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -27,4 +27,3 @@ internal data class PendingThreePid(
|
||||
// For Msisdn only
|
||||
val submitUrl: String?
|
||||
)
|
||||
|
||||
|
@ -120,12 +120,16 @@ class ThreePidsSettingsFragment @Inject constructor(
|
||||
|
||||
// Check that phone number is valid
|
||||
if (!msisdn.startsWith("+")) {
|
||||
viewModel.handle(ThreePidsSettingsAction.ChangeState(ThreePidsSettingsState.AddingPhoneNumber(getString(R.string.login_msisdn_error_not_international))))
|
||||
viewModel.handle(
|
||||
ThreePidsSettingsAction.ChangeState(ThreePidsSettingsState.AddingPhoneNumber(getString(R.string.login_msisdn_error_not_international)))
|
||||
)
|
||||
return
|
||||
}
|
||||
|
||||
if (!msisdn.isMsisdn()) {
|
||||
viewModel.handle(ThreePidsSettingsAction.ChangeState(ThreePidsSettingsState.AddingPhoneNumber(getString(R.string.login_msisdn_error_other))))
|
||||
viewModel.handle(
|
||||
ThreePidsSettingsAction.ChangeState(ThreePidsSettingsState.AddingPhoneNumber(getString(R.string.login_msisdn_error_other)))
|
||||
)
|
||||
return
|
||||
}
|
||||
|
||||
|
@ -156,7 +156,6 @@ class ThreePidsSettingsViewModel @AssistedInject constructor(
|
||||
_viewEvents.post(ThreePidsSettingsViewEvents.Failure(failure))
|
||||
}
|
||||
})
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user