When download start, mark the query cache operation finished to avoid bug behavior

This commit is contained in:
DreamPiggy 2022-07-23 21:59:14 +08:00
parent 2729096221
commit 3d1197b820
1 changed files with 5 additions and 0 deletions

View File

@ -382,6 +382,11 @@ static id<SDImageLoader> _defaultImageLoader;
cacheType:(SDImageCacheType)cacheType
progress:(nullable SDImageLoaderProgressBlock)progressBlock
completed:(nullable SDInternalCompletionBlock)completedBlock {
// Mark the cache operation end
@synchronized (operation) {
operation.cacheOperation = nil;
}
// Grab the image loader to use
id<SDImageLoader> imageLoader;
if ([context[SDWebImageContextImageLoader] conformsToProtocol:@protocol(SDImageLoader)]) {