marinofaggiana 4 anos atrás
pai
commit
1ada56947e

+ 4 - 6
iOSClient/Main/CCMain.m

@@ -444,13 +444,11 @@
     NSDictionary *userInfo = notification.userInfo;
     NSDictionary *userInfo = notification.userInfo;
     tableMetadata *metadata = userInfo[@"metadata"];
     tableMetadata *metadata = userInfo[@"metadata"];
     
     
-    if (![metadata.serverUrl isEqualToString:self.serverUrl]) { return; }
-    
-    BOOL isFolderEncrypted = [CCUtility isFolderEncrypted:metadata.serverUrl e2eEncrypted:nil account:appDelegate.account urlBase: appDelegate.urlBase];
-    if (isFolderEncrypted) {
-        [self readFolder:metadata.serverUrl];
-    } else {
+    if (metadata) {
+         if (![metadata.serverUrl isEqualToString:self.serverUrl]) { return; }
         [self reloadDatasource:self.serverUrl ocId:nil];
         [self reloadDatasource:self.serverUrl ocId:nil];
+    } else {
+        [self readFolder:metadata.serverUrl];
     }
     }
 }
 }
 
 

+ 2 - 0
iOSClient/Main/Collection/NCCollectionViewCommon.swift

@@ -287,6 +287,8 @@ class NCCollectionViewCommon: UIViewController, UIGestureRecognizerDelegate, UIS
                     }
                     }
                 }
                 }
             }
             }
+        } else {
+            self.reloadDataSourceNetwork()
         }
         }
     }
     }
     
     

+ 1 - 3
iOSClient/Networking/NCNetworkingE2EE.swift

@@ -96,9 +96,7 @@ import Alamofire
                                         NCCommunication.shared.lockE2EEFolder(fileId: tableLock.fileId, e2eToken: tableLock.e2eToken, method: "DELETE") { (_, _, _, _) in }
                                         NCCommunication.shared.lockE2EEFolder(fileId: tableLock.fileId, e2eToken: tableLock.e2eToken, method: "DELETE") { (_, _, _, _) in }
                                     }
                                     }
                                     if errorCode == 0 {
                                     if errorCode == 0 {
-                                        if let metadata = NCManageDatabase.sharedInstance.getMetadataFromOcId(ocId) {
-                                            NotificationCenter.default.postOnMainThread(name: k_notificationCenter_createFolder, userInfo: ["metadata": metadata])
-                                        }
+                                        NotificationCenter.default.postOnMainThread(name: k_notificationCenter_createFolder, userInfo: nil)
                                     }
                                     }
                                     completion(errorCode, errorDescription ?? "")
                                     completion(errorCode, errorDescription ?? "")
                                 }
                                 }