diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt b/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt index 0c1ba824ec..7214ecd940 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt @@ -232,7 +232,7 @@ class CoverCache(val context: Context) { val file = getCoverFile(manga) if (deleteCustom) deleteCustomCover(manga) if (file.exists()) { - context.imageLoader.memoryCache.remove(MemoryCache.Key(file.name)) + context.imageLoader.memoryCache.remove(MemoryCache.Key(manga.key())) file.delete() } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt index 83af2c8074..f790f156f1 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt @@ -5,6 +5,8 @@ import android.graphics.Bitmap import android.net.Uri import android.os.Environment import coil.Coil +import coil.imageLoader +import coil.memory.MemoryCache import coil.request.CachePolicy import coil.request.ImageRequest import coil.request.Parameters @@ -370,6 +372,7 @@ class MangaDetailsPresenter( .build() if (Coil.imageLoader(preferences.context).execute(request) is SuccessResult) { + preferences.context.imageLoader.memoryCache.remove(MemoryCache.Key(manga.key())) withContext(Dispatchers.Main) { controller.setPaletteColor() }