diff --git a/AutoCat.xcodeproj/project.pbxproj b/AutoCat.xcodeproj/project.pbxproj index 8be4e89..3553b17 100644 --- a/AutoCat.xcodeproj/project.pbxproj +++ b/AutoCat.xcodeproj/project.pbxproj @@ -619,7 +619,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CODE_SIGN_ENTITLEMENTS = AutoCat/AutoCat.entitlements; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 14; + CURRENT_PROJECT_VERSION = 15; DEVELOPMENT_TEAM = 46DTTB8X4S; INFOPLIST_FILE = AutoCat/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 13.0; @@ -641,7 +641,7 @@ ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; CODE_SIGN_ENTITLEMENTS = AutoCat/AutoCat.entitlements; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 14; + CURRENT_PROJECT_VERSION = 15; DEVELOPMENT_TEAM = 46DTTB8X4S; INFOPLIST_FILE = AutoCat/Info.plist; IPHONEOS_DEPLOYMENT_TARGET = 13.0; diff --git a/AutoCat/Controllers/MainSplitController.swift b/AutoCat/Controllers/MainSplitController.swift index 0cf1b20..15c947a 100644 --- a/AutoCat/Controllers/MainSplitController.swift +++ b/AutoCat/Controllers/MainSplitController.swift @@ -31,7 +31,7 @@ class MainSplitController: UISplitViewController, UISplitViewControllerDelegate let tabController = splitViewController.viewControllers.first as? UITabBarController let selectedNavController = tabController?.selectedViewController as? UINavigationController - if selectedNavController?.viewControllers[1] is ReportController { + if selectedNavController?.viewControllers.count ?? 0 > 1 && selectedNavController?.viewControllers[1] is ReportController { if let controllers = selectedNavController?.popToRootViewController(animated: false) { let nav = UINavigationController() nav.setViewControllers(controllers, animated: true)