Skip to content

Commit

Permalink
Remove nonnull requirement from BFTask.taskFromExecutor(_ ,block:).
Browse files Browse the repository at this point in the history
  • Loading branch information
nlutsenko committed Jan 11, 2016
1 parent 0628d56 commit 50aa188
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Bolts/Common/BFTask.h
Expand Up @@ -107,7 +107,7 @@ typedef __nullable id(^BFContinuationBlock)(BFTask<ResultType> *task);
If block returns a BFTask, then the task returned from
this method will not be completed until that task is completed.
*/
+ (instancetype)taskFromExecutor:(BFExecutor *)executor withBlock:(id (^)())block;
+ (instancetype)taskFromExecutor:(BFExecutor *)executor withBlock:(nullable id (^)())block;

// Properties that will be set on the task once it is completed.

Expand Down
3 changes: 1 addition & 2 deletions Bolts/Common/BFTask.m
Expand Up @@ -199,8 +199,7 @@ + (instancetype)taskWithDelay:(int)millis
return tcs.task;
}

+ (instancetype)taskFromExecutor:(BFExecutor *)executor
withBlock:(id (^)())block {
+ (instancetype)taskFromExecutor:(BFExecutor *)executor withBlock:(nullable id (^)())block {
return [[self taskWithResult:nil] continueWithExecutor:executor withBlock:^id(BFTask *task) {
return block();
}];
Expand Down

0 comments on commit 50aa188

Please sign in to comment.