Skip to content

Commit

Permalink
task cancelled error message
Browse files Browse the repository at this point in the history
  • Loading branch information
Artur Chrusciel committed Jan 16, 2018
1 parent 89d9b7a commit a46bf81
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ios/RNFetchBlobRequest.m
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,11 @@ - (void) URLSession:(NSURLSession *)session task:(NSURLSessionTask *)task didCom
});

if (error) {
errMsg = [error localizedDescription];
if (error.domain == NSURLErrorDomain && error.code == NSURLErrorCancelled) {
errMsg = @"task cancelled";
} else {
errMsg = [error localizedDescription];
}
}

if (respFile) {
Expand Down

0 comments on commit a46bf81

Please sign in to comment.