title: FileManager memory leak
body: <p>I have a memory leak problem with FileManager.
  My code is like this;</p>
  
  <pre><code>    func saveImageToDocumentDirectory(image: UIImage, name: String, then handler: @escaping () -&gt; Void) {
       DispatchQueue.global(qos: .background).async {
          autoreleasepool {
              let documentsDirectory = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).first!
              let fileName = name // name of the image to be saved
              let fileURL = documentsDirectory.appendingPathComponent(fileName)
              if let data = UIImageJPEGRepresentation(image, 0.2),!FileManager.default.fileExists(atPath: fileURL.path){
                  do {
                      try data.write(to: fileURL)
                      handler()
                      print("file saved")
                  } catch {
                      handler()
                      print("error saving file:", error)
                  }
              }
          }
      }
  }
  </code></pre>
  
  <p>After the handler response it does not remove from memory. For example It starts with 60MB then It rises 190MB, when all images saved, It does not down to 60MB.</p>