You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Special case: If user query image in list for the same URL, to avoid decode and write **same** image object into disk cache multiple times, we query and check memory cache here again.
692
-
if (shouldCacheToMemory && self.config.shouldCacheImagesInMemory) {
693
-
diskImage = [self.memoryCache objectForKey:key];
693
+
// Special case: If user query image in list for the same URL, to avoid decode and write **same** image object into disk cache multiple times, we query and check memory cache here again. See: #3523
694
+
// This because disk operation can be async, previous sync check of `memory cache miss`, does not gurantee current check of `memory cache miss`
695
+
if (!shouldQueryDiskSync) {
696
+
// First check the in-memory cache...
697
+
if (!shouldQueryDiskOnly) {
698
+
diskImage = [selfimageFromMemoryCacheForKey:key];
699
+
}
694
700
}
695
701
// decode image data only if in-memory cache missed
0 commit comments