Browse Source

test fix: is pushing the same view controller instance ?

marinofaggiana 4 years ago
parent
commit
8053209f74
1 changed files with 6 additions and 1 deletions
  1. 6 1
      iOSClient/Main/Collection Common/NCCollectionViewCommon.swift

+ 6 - 1
iOSClient/Main/Collection Common/NCCollectionViewCommon.swift

@@ -188,9 +188,14 @@ class NCCollectionViewCommon: UIViewController, UIGestureRecognizerDelegate, UIS
     override func viewDidAppear(_ animated: Bool) {
         super.viewDidAppear(animated)
         
-        pushed = false
         reloadDataSourceNetwork()
     }
+    
+    override func viewDidDisappear(_ animated: Bool) {
+        super.viewDidDisappear(animated)
+        
+        pushed = false
+    }
         
     func presentationControllerDidDismiss( _ presentationController: UIPresentationController) {
         let viewController = presentationController.presentedViewController