Commit 62319c1e by Dima Bart

Rename from getter to property name: isCancelled -> cancelled

parent 91e65606
...@@ -49,11 +49,11 @@ ...@@ -49,11 +49,11 @@
XCTAssertTrue(operation.isReady); XCTAssertTrue(operation.isReady);
[operation start]; [operation start];
XCTAssertTrue(operation.isExecuting); XCTAssertTrue(operation.executing);
[operation finishExecution]; [operation finishExecution];
XCTAssertTrue(operation.isFinished); XCTAssertTrue(operation.isFinished);
XCTAssertFalse(operation.isCancelled); XCTAssertFalse(operation.cancelled);
} }
- (void)testCancelledExecutionFlow - (void)testCancelledExecutionFlow
...@@ -62,10 +62,10 @@ ...@@ -62,10 +62,10 @@
XCTAssertTrue(operation.isReady); XCTAssertTrue(operation.isReady);
[operation start]; [operation start];
XCTAssertTrue(operation.isExecuting); XCTAssertTrue(operation.executing);
[operation cancel]; [operation cancel];
XCTAssertTrue(operation.isCancelled); XCTAssertTrue(operation.cancelled);
XCTAssertFalse(operation.isFinished); XCTAssertFalse(operation.isFinished);
[operation cancelExecution]; [operation cancelExecution];
......
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
- (void)finishWithCheckout:(BUYCheckout *)checkout - (void)finishWithCheckout:(BUYCheckout *)checkout
{ {
if (self.isCancelled) { if (self.cancelled) {
return; return;
} }
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
- (void)finishWithError:(NSError *)error - (void)finishWithError:(NSError *)error
{ {
if (self.isCancelled) { if (self.cancelled) {
return; return;
} }
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
- (void)startExecution - (void)startExecution
{ {
if (self.isCancelled) { if (self.cancelled) {
return; return;
} }
......
...@@ -97,7 +97,7 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse * ...@@ -97,7 +97,7 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse *
- (void)startExecution - (void)startExecution
{ {
if (self.isCancelled) { if (self.cancelled) {
return; return;
} }
...@@ -126,13 +126,13 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse * ...@@ -126,13 +126,13 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse *
- (NSURLSessionDataTask *)requestUsingPollingIfNeeded:(NSURLRequest *)request completion:(BUYRequestJSONCompletion)completion - (NSURLSessionDataTask *)requestUsingPollingIfNeeded:(NSURLRequest *)request completion:(BUYRequestJSONCompletion)completion
{ {
if (self.isCancelled) { if (self.cancelled) {
return nil; return nil;
} }
return [self request:request completion:^(NSDictionary *json, NSHTTPURLResponse *response, NSError *error) { return [self request:request completion:^(NSDictionary *json, NSHTTPURLResponse *response, NSError *error) {
if (self.isCancelled) { if (self.cancelled) {
return; return;
} }
...@@ -145,7 +145,7 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse * ...@@ -145,7 +145,7 @@ typedef void (^BUYRequestJSONCompletion)(NSDictionary *json, NSHTTPURLResponse *
if (self.pollingHandler && self.pollingHandler(json, response, error)) { if (self.pollingHandler && self.pollingHandler(json, response, error)) {
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(self.pollingInterval * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{ dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(self.pollingInterval * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
if (self.isCancelled) { if (self.cancelled) {
return; return;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment