Correct split view collapse logic for when running side by side.

This commit is contained in:
Maurice Parker 2019-12-01 12:04:28 -06:00
parent 87a82eb290
commit 6ed1c27856
1 changed files with 4 additions and 3 deletions

View File

@ -1089,11 +1089,12 @@ extension SceneCoordinator: UISplitViewControllerDelegate {
}
if let articleViewController = (secondaryViewController as? UINavigationController)?.topViewController as? ArticleViewController {
masterNavigationController.pushViewController(articleViewController, animated: false)
return false
if currentArticle != nil {
masterNavigationController.pushViewController(articleViewController, animated: false)
}
}
return currentArticle == nil
return true
}
func splitViewController(_ splitViewController: UISplitViewController, separateSecondaryFrom primaryViewController: UIViewController) -> UIViewController? {