diff --git a/AFNetworking/AFURLConnectionOperation.h b/AFNetworking/AFURLConnectionOperation.h index 2ce5609..0ac9e10 100644 --- a/AFNetworking/AFURLConnectionOperation.h +++ b/AFNetworking/AFURLConnectionOperation.h @@ -44,7 +44,6 @@ - `connection:didSendBodyData:totalBytesWritten:totalBytesExpectedToWrite:` - `connection:willCacheResponse:` - `connectionShouldUseCredentialStorage:` - - `connection:needNewBodyStream:` - `connection:willSendRequestForAuthenticationChallenge:` If any of these methods are overridden in a subclass, they _must_ call the `super` implementation first. @@ -293,7 +292,6 @@ NSCoding, NSCopying> */ - (void)setRedirectResponseBlock:(NSURLRequest * (^)(NSURLConnection *connection, NSURLRequest *request, NSURLResponse *redirectResponse))block; - /** Sets a block to be executed to modify the response a connection will cache, if any, as handled by the `NSURLConnectionDelegate` method `connection:willCacheResponse:`. diff --git a/AFNetworking/AFURLConnectionOperation.m b/AFNetworking/AFURLConnectionOperation.m index 92dad72..b71f5e8 100644 --- a/AFNetworking/AFURLConnectionOperation.m +++ b/AFNetworking/AFURLConnectionOperation.m @@ -687,18 +687,6 @@ willSendRequestForAuthenticationChallenge:(NSURLAuthenticationChallenge *)challe return self.shouldUseCredentialStorage; } -- (NSInputStream *)connection:(NSURLConnection __unused *)connection - needNewBodyStream:(NSURLRequest *)request -{ - if ([request.HTTPBodyStream conformsToProtocol:@protocol(NSCopying)]) { - return [request.HTTPBodyStream copy]; - } else { - [self cancelConnection]; - - return nil; - } -} - - (NSURLRequest *)connection:(NSURLConnection *)connection willSendRequest:(NSURLRequest *)request redirectResponse:(NSURLResponse *)redirectResponse