Browse Source

Set download delegate error on failed move to destination

Mattt Thompson 11 years ago
parent
commit
265ae87c76
1 changed files with 3 additions and 1 deletions
  1. 3 1
      Source/Alamofire.swift

+ 3 - 1
Source/Alamofire.swift

@@ -819,7 +819,9 @@ extension Request {
                 var fileManagerError: NSError?
 
                 NSFileManager.defaultManager().moveItemAtURL(location, toURL: destination, error: &fileManagerError)
-                // TODO: NSNotification on failure
+                if fileManagerError != nil {
+                    self.error = fileManagerError
+                }
             }
         }