Marino Faggiana 7 anos atrás
pai
commit
e1ec9009e8
1 arquivos alterados com 3 adições e 4 exclusões
  1. 3 4
      PickerFileProvider/FileProvider.swift

+ 3 - 4
PickerFileProvider/FileProvider.swift

@@ -46,13 +46,12 @@ class FileProvider: NSFileProviderExtension {
         
         if #available(iOSApplicationExtension 11.0, *) {
             
+            // Only iOS 11
+            
         } else {
             
             NSFileCoordinator().coordinate(writingItemAt: self.documentStorageURL, options: [], error: nil, byAccessor: { newURL in
-                do {
-                    try FileManager.default.createDirectory(at: newURL, withIntermediateDirectories: true, attributes: nil)
-                } catch {
-                }
+                try? FileManager.default.createDirectory(at: newURL, withIntermediateDirectories: true, attributes: nil)
             })
         }
     }