Browse Source

combine handleLoginSuccess() and handleProfileInfoClosed() to one function

B. Petersen 5 years ago
parent
commit
1a115f4c73
1 changed files with 2 additions and 6 deletions
  1. 2 6
      deltachat-ios/Coordinator/AppCoordinator.swift

+ 2 - 6
deltachat-ios/Coordinator/AppCoordinator.swift

@@ -178,21 +178,17 @@ extension AppCoordinator: WelcomeCoordinator {
         welcomeController?.present(loginController, animated: true, completion: nil)
     }
 
-    func handleLoginSuccess() {
-        presentTabBarController()
-    }
-
     func handleQRAccountCreationSuccess() {
         let profileInfoController = ProfileInfoViewController(context: dcContext)
         let profileInfoNav = UINavigationController(rootViewController: profileInfoController)
         profileInfoNav.modalPresentationStyle = .fullScreen
         let coordinator = EditSettingsCoordinator(dcContext: dcContext, navigationController: profileInfoNav)
         profileInfoController.coordinator = coordinator
-        profileInfoController.onClose = handleProfileInfoClosed
+        profileInfoController.onClose = handleLoginSuccess
         welcomeController?.present(profileInfoNav, animated: true, completion: nil)
     }
 
-    private func handleProfileInfoClosed() {
+    func handleLoginSuccess() {
         presentTabBarController()
     }