diff --git a/iOS/Projects/App/Sources/CommonScene/Coordinator/AppCoordinator.swift b/iOS/Projects/App/Sources/CommonScene/Coordinator/AppCoordinator.swift index e42b9044..104def73 100644 --- a/iOS/Projects/App/Sources/CommonScene/Coordinator/AppCoordinator.swift +++ b/iOS/Projects/App/Sources/CommonScene/Coordinator/AppCoordinator.swift @@ -9,6 +9,8 @@ import Coordinator import UIKit +// MARK: - AppCoordinator + final class AppCoordinator: AppCoordinating { var navigationController: UINavigationController var childCoordinators: [Coordinating] = [] @@ -36,3 +38,11 @@ final class AppCoordinator: AppCoordinating { // (TabBarController 추가되면 로직 추가) (todo) } } + +// MARK: CoordinatorFinishDelegate + +extension AppCoordinator: CoordinatorFinishDelegate { + func flowDidFinished(childCoordinator: Coordinating) { + // TODO: 로그아웃 Flow, 로그인 Flow (앱 실행 도중 발생되는 분기처리) + } +} diff --git a/iOS/Projects/App/Sources/TabBarScene/Coordinator/TabBarCoordinator.swift b/iOS/Projects/App/Sources/TabBarScene/Coordinator/TabBarCoordinator.swift index df722bf7..4e8ed94d 100644 --- a/iOS/Projects/App/Sources/TabBarScene/Coordinator/TabBarCoordinator.swift +++ b/iOS/Projects/App/Sources/TabBarScene/Coordinator/TabBarCoordinator.swift @@ -33,7 +33,7 @@ final class TabBarCoordinator: TabBarCoordinating { let tabBarController = makeTabBarController(tabBarViewControllers: tabBarViewControllers) navigationController.pushViewController(tabBarController, animated: false) } - + private func makePageNavigationController(page: TabBarPage) -> UINavigationController { let navigationController = UINavigationController() let tabBarItem = UITabBarItem(title: page.title, image: page.image, selectedImage: page.selectedImage) @@ -42,7 +42,6 @@ final class TabBarCoordinator: TabBarCoordinating { return navigationController } - private func startTabBarCoordinator(page: TabBarPage, pageNavigationViewController: UINavigationController) { switch page { case .home: diff --git a/iOS/Projects/Features/Record/Sources/Common/Coordinator/RecordFeatureCoordinator.swift b/iOS/Projects/Features/Record/Sources/Common/Coordinator/RecordFeatureCoordinator.swift index 9283395c..49237a47 100644 --- a/iOS/Projects/Features/Record/Sources/Common/Coordinator/RecordFeatureCoordinator.swift +++ b/iOS/Projects/Features/Record/Sources/Common/Coordinator/RecordFeatureCoordinator.swift @@ -48,7 +48,12 @@ public final class RecordFeatureCoordinator: RecordFeatureCoordinating { // MARK: CoordinatorFinishDelegate extension RecordFeatureCoordinator: CoordinatorFinishDelegate { - public func flowDidFinished(childCoordinator _: Coordinating) {} + public func flowDidFinished(childCoordinator: Coordinating) { + childCoordinators = childCoordinators.filter { + $0.flow != childCoordinator.flow + } + navigationController.popToRootViewController(animated: false) + } } // MARK: WorkoutSettingCoordinatorFinishDelegate