2
0
Эх сурвалжийг харах

[PR #1722] Update README for proper error checking in download.

Jon Shier 9 жил өмнө
parent
commit
2034f4c872
1 өөрчлөгдсөн 1 нэмэгдсэн , 1 устгасан
  1. 1 1
      README.md

+ 1 - 1
README.md

@@ -623,7 +623,7 @@ let destination: DownloadRequest.DownloadFileDestination = { _, _ in
 Alamofire.download(urlString, to: destination).response { response in
     print(response)
 
-	if response.result.isSuccess, let imagePath = response.destinationURL?.path {
+	if response.error == nil, let imagePath = response.destinationURL?.path {
 	    let image = UIImage(contentsOfFile: imagePath)
 	}
 }