...
|
...
|
@@ -138,7 +138,7 @@ static NSString *const kCompletedCallbackKey = @"completed"; |
|
|
if (!sself) return;
|
|
|
__block NSArray *callbacksForURL;
|
|
|
dispatch_sync(sself.barrierQueue, ^{
|
|
|
callbacksForURL = sself.URLCallbacks[url];
|
|
|
callbacksForURL = [sself.URLCallbacks[url] copy];
|
|
|
});
|
|
|
for (NSDictionary *callbacks in callbacksForURL) {
|
|
|
SDWebImageDownloaderProgressBlock callback = callbacks[kProgressCallbackKey];
|
...
|
...
|
@@ -150,7 +150,7 @@ static NSString *const kCompletedCallbackKey = @"completed"; |
|
|
if (!sself) return;
|
|
|
__block NSArray *callbacksForURL;
|
|
|
dispatch_barrier_sync(sself.barrierQueue, ^{
|
|
|
callbacksForURL = sself.URLCallbacks[url];
|
|
|
callbacksForURL = [sself.URLCallbacks[url] copy];
|
|
|
if (finished) {
|
|
|
[sself.URLCallbacks removeObjectForKey:url];
|
|
|
}
|
...
|
...
|
|