diff --git a/SDWebImage/SDWebImageManager.m b/SDWebImage/SDWebImageManager.m index f4f98832..3c83301d 100644 --- a/SDWebImage/SDWebImageManager.m +++ b/SDWebImage/SDWebImageManager.m @@ -122,8 +122,8 @@ } __block id subOperation = [self.imageDownloader downloadImageWithURL:url options:downloaderOptions progress:progressBlock completed:^(UIImage *downloadedImage, NSData *data, NSError *error, BOOL finished) { - BOOL imageIsGIF = [data isGIF]; - if (imageIsGIF) + BOOL isImageGIF = [data isGIF]; + if (isImageGIF) { downloadedImage = [UIImage animatedGIFWithData:data]; } @@ -156,7 +156,7 @@ { dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_HIGH, 0), ^ { - UIImage *transformedImage = imageIsGIF ? downloadedImage : [self.delegate imageManager:self transformDownloadedImage:downloadedImage withURL:url]; + UIImage *transformedImage = isImageGIF ? downloadedImage : [self.delegate imageManager:self transformDownloadedImage:downloadedImage withURL:url]; dispatch_async(dispatch_get_main_queue(), ^ { @@ -165,7 +165,7 @@ if (transformedImage && finished) { - NSData *dataToStore = imageIsGIF ? data : nil; + NSData *dataToStore = isImageGIF ? data : nil; [self.imageCache storeImage:transformedImage imageData:dataToStore forKey:key toDisk:cacheOnDisk]; } });