fix image cache

This commit is contained in:
Bnyro 2022-08-25 11:29:12 +02:00
parent 460474d57e
commit ff16e14b33

View File

@ -16,10 +16,10 @@ object ImageHelper {
* Initialize the image loader * Initialize the image loader
*/ */
fun initializeImageLoader(context: Context) { fun initializeImageLoader(context: Context) {
val maxImageCacheSize = PreferenceHelper.getInt( val maxImageCacheSize = PreferenceHelper.getString(
PreferenceKeys.MAX_IMAGE_CACHE, PreferenceKeys.MAX_IMAGE_CACHE,
128 "128"
) ).toInt()
val diskCache = DiskCache.Builder() val diskCache = DiskCache.Builder()
.directory(context.filesDir.resolve("coil")) .directory(context.filesDir.resolve("coil"))