Revert "test Jetsam dont kill sulfur please 😭"

This reverts commit 53ae9b2d23.
This commit is contained in:
Francesco 2025-06-03 18:05:12 +02:00
parent cd73becd03
commit 2b1f4807fd
3 changed files with 5 additions and 6 deletions

View file

@ -14,7 +14,7 @@ class KingfisherCacheManager {
private let jpegCompressionQuality: CGFloat = 0.7
static let shared = KingfisherCacheManager()
private let maxDiskCacheSize: UInt = 16 * 1024 * 1024
private let maxDiskCacheSize: UInt = 64 * 1024 * 1024
private let maxCacheAgeInDays: TimeInterval = 7
private let imageCachingEnabledKey = "imageCachingEnabled"
@ -39,9 +39,7 @@ class KingfisherCacheManager {
@objc private func clearMemoryCacheOnWarning() {
KingfisherManager.shared.cache.clearMemoryCache()
KingfisherManager.shared.cache.clearDiskCache {
Logger.shared.log("Cleared memory and disk cache due to memory warning", type: "Debug")
}
Logger.shared.log("Cleared memory cache due to memory warning", type: "Debug")
}
func configureKingfisher() {
@ -52,7 +50,7 @@ class KingfisherCacheManager {
.days(Int(maxCacheAgeInDays)) : .seconds(1)
cache.memoryStorage.config.totalCostLimit = isCachingEnabled ?
4 * 1024 * 1024 : 0
12 * 1024 * 1024 : 0
cache.memoryStorage.config.cleanInterval = 60

View file

@ -270,6 +270,7 @@ struct EpisodeCell: View {
.onFailure { error in
Logger.shared.log("Failed to load episode image: \(error)", type: "Error")
}
.cacheMemoryOnly(!KingfisherCacheManager.shared.isCachingEnabled)
.resizable()
.aspectRatio(16/9, contentMode: .fill)
.frame(width: 100, height: 56)

View file

@ -616,7 +616,7 @@ struct MediaInfoView: View {
.frame(width: max(width * CGFloat(progress), 8), height: 48)
.mask(
HStack {
if progress < 0.05 && progress != 0 {
if progress < 0.05 {
RoundedRectangle(cornerRadius: 24)
.frame(width: 8)
} else {