mirror of
https://github.com/zhigang1992/RestKit.git
synced 2026-04-01 09:31:17 +08:00
Fixes #428, related to a misspelling in the request:didReceiveData:totalBytesReceived:totalBytesExpectedToReceive:
This commit is contained in:
@@ -516,7 +516,7 @@ typedef void(^RKRequestDidFailLoadWithErrorBlock)(NSError *error);
|
||||
/**
|
||||
* Sent when request has received data from remote site
|
||||
*/
|
||||
- (void)request:(RKRequest*)request didReceiveData:(NSInteger)bytesReceived totalBytesReceived:(NSInteger)totalBytesReceived totalBytesExectedToReceive:(NSInteger)totalBytesExpectedToReceive;
|
||||
- (void)request:(RKRequest*)request didReceiveData:(NSInteger)bytesReceived totalBytesReceived:(NSInteger)totalBytesReceived totalBytesExpectedToReceive:(NSInteger)totalBytesExpectedToReceive;
|
||||
|
||||
/**
|
||||
* Sent to the delegate when a request was cancelled
|
||||
|
||||
@@ -181,8 +181,8 @@ extern NSString* cacheURLKey;
|
||||
- (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data {
|
||||
[_body appendData:data];
|
||||
[_request invalidateTimeoutTimer];
|
||||
if ([[_request delegate] respondsToSelector:@selector(request:didReceiveData:totalBytesReceived:totalBytesExectedToReceive:)]) {
|
||||
[[_request delegate] request:_request didReceiveData:[data length] totalBytesReceived:[_body length] totalBytesExectedToReceive:_httpURLResponse.expectedContentLength];
|
||||
if ([[_request delegate] respondsToSelector:@selector(request:didReceiveData:totalBytesReceived:totalBytesExpectedToReceive:)]) {
|
||||
[[_request delegate] request:_request didReceiveData:[data length] totalBytesReceived:[_body length] totalBytesExpectedToReceive:_httpURLResponse.expectedContentLength];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user