marinofaggiana 4 年之前
父節點
當前提交
6e40be1aa6
共有 1 個文件被更改,包括 5 次插入5 次删除
  1. 5 5
      iOSClient/Main/Collection/NCCollectionViewCommon.swift

+ 5 - 5
iOSClient/Main/Collection/NCCollectionViewCommon.swift

@@ -733,6 +733,11 @@ extension NCCollectionViewCommon: UICollectionViewDelegate {
             return
         }
         
+        if metadata.e2eEncrypted && !CCUtility.isEnd(toEndEnabled: appDelegate.account) {
+            NCContentPresenter.shared.messageNotification("_info_", description: "_e2e_goto_settings_for_enable_", delay: TimeInterval(k_dismissAfterSecond), type: NCContentPresenter.messageType.info, errorCode: Int(k_CCErrorE2EENotEnabled), forced: true)
+            return
+        }
+        
         if metadata.directory {
             
             guard let serverUrlPush = CCUtility.stringAppendServerUrl(metadataPush!.serverUrl, addFileName: metadataPush!.fileName) else { return }
@@ -759,11 +764,6 @@ extension NCCollectionViewCommon: UICollectionViewDelegate {
             
         } else {
             
-            if metadataFolder?.e2eEncrypted ?? false && !CCUtility.isEnd(toEndEnabled: appDelegate.account) {
-                NCContentPresenter.shared.messageNotification("_info_", description: "_e2e_goto_settings_for_enable_", delay: TimeInterval(k_dismissAfterSecond), type: NCContentPresenter.messageType.info, errorCode: Int(k_CCErrorE2EENotEnabled), forced: true)
-                return
-            }
-            
             if metadata.typeFile == k_metadataTypeFile_document && NCUtility.shared.isDirectEditing(account: metadata.account, contentType: metadata.contentType) != nil {
                 if NCCommunication.shared.isNetworkReachable() {
                     performSegue(withIdentifier: "segueDetail", sender: self)