From ba9a742999f5d5baeae5df0768bd738c233cc588 Mon Sep 17 00:00:00 2001 From: Adlai Holler Date: Thu, 17 Sep 2015 14:48:42 -0700 Subject: [PATCH] Fix nullability of ASImageDownloaderProtocol to conform to ASBasicImageDownloader behavior --- AsyncDisplayKit/Details/ASImageProtocols.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/AsyncDisplayKit/Details/ASImageProtocols.h b/AsyncDisplayKit/Details/ASImageProtocols.h index 2235dafe17..8a235083ca 100644 --- a/AsyncDisplayKit/Details/ASImageProtocols.h +++ b/AsyncDisplayKit/Details/ASImageProtocols.h @@ -43,13 +43,11 @@ NS_ASSUME_NONNULL_BEGIN @param completion The block to be invoked when the download has completed, or has failed. @param image The image that was downloaded, if the image could be successfully downloaded; nil otherwise. @param error An error describing why the download of `URL` failed, if the download failed; nil otherwise. - @discussion If `URL` is nil, `completion` will be invoked immediately with a nil image and an error describing why the - download failed. This method is likely to be called on the main thread, so any custom implementations should make - sure to background any expensive download operations. + @discussion This method is likely to be called on the main thread, so any custom implementations should make sure to background any expensive download operations. @result An opaque identifier to be used in canceling the download, via `cancelImageDownloadForIdentifier:`. You must retain the identifier if you wish to use it later. */ -- (id)downloadImageWithURL:(nullable NSURL *)URL +- (id)downloadImageWithURL:(NSURL *)URL callbackQueue:(nullable dispatch_queue_t)callbackQueue downloadProgressBlock:(void (^ _Nullable)(CGFloat progress))downloadProgressBlock completion:(void (^ _Nullable)(CGImageRef _Nullable image, NSError * _Nullable error))completion;