Move the core logic in LoginScreenCoordinator into the ViewModel. (#3348)

This commit is contained in:
Doug
2024-10-01 13:09:45 +01:00
committed by GitHub
parent 5f4c2890f6
commit 268d9f7479
29 changed files with 382 additions and 388 deletions
@@ -37,10 +37,8 @@ class ServerConfirmationScreenViewModel: ServerConfirmationScreenViewModelType,
authenticationService.homeserver
.receive(on: DispatchQueue.main)
.sink { [weak self] homeserver in
guard let self else { return }
state.homeserverAddress = homeserver.address
}
.map(\.address)
.weakAssign(to: \.state.homeserverAddress, on: self)
.store(in: &cancellables)
}