Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

Commit

Permalink
[Issue #1701] Validating responses of download tasks
Browse files Browse the repository at this point in the history
  • Loading branch information
mattt committed Dec 20, 2013
1 parent 1578979 commit 8763dcc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions AFNetworking/AFURLSessionManager.m
Expand Up @@ -178,10 +178,10 @@ - (void)URLSession:(__unused NSURLSession *)session
} else {
dispatch_async(url_session_manager_processing_queue(), ^{
NSError *serializationError = nil;
responseObject = [manager.responseSerializer responseObjectForResponse:task.response data:[NSData dataWithData:self.mutableData] error:&serializationError];

if (self.downloadFileURL) {
responseObject = self.downloadFileURL;
} else {
responseObject = [manager.responseSerializer responseObjectForResponse:task.response data:[NSData dataWithData:self.mutableData] error:&serializationError];
}

if (responseObject) {
Expand Down

0 comments on commit 8763dcc

Please sign in to comment.