Selecting a server that doesn't support login now fails instead of letting you continue to a failure later. (#3342)

* Fail configuration of the authentication service if the homeserver doesn't support login.

* Move the ServerSelectionCoordinator logic into the ViewModel.

- Handle the new login alert.
- Add more tests
This commit is contained in:
Doug
2024-09-27 13:58:05 +01:00
committed by GitHub
parent 8a3994016d
commit 17dfe1359a
17 changed files with 263 additions and 139 deletions
@@ -8,8 +8,8 @@
import Foundation
enum ServerSelectionScreenViewModelAction {
/// The user would like to use the homeserver at the given address.
case confirm(homeserverAddress: String)
/// The homeserver selection has been updated.
case updated
/// Dismiss the view without using the entered address.
case dismiss
}
@@ -74,6 +74,8 @@ enum ServerSelectionScreenErrorType: Hashable {
case invalidWellKnownAlert(String)
/// An alert that allows the user to learn about sliding sync.
case slidingSyncAlert
/// An alert that informs the user that login isn't supported.
case loginAlert
/// An alert that informs the user that registration isn't supported.
case registrationAlert
}