There's a bug currently where PINDiskCache will always trim cache size to 50MB when creating since it defaults to 50MB in the init, and immediately trims cache in [self initializeDiskProperties];. This is obviously not ideal since if we specify a cache size >50MB then we will constantly be having to refetch assets on each app open since it will trim to 50MB each time.
Proposed fix:
Add two new fields to designated init to allow passing in custom byteLimit and ageLimit
Keep convenience init to maintain API stability that defaults to 50MB/30 days
There's a bug currently where
PINDiskCache
will always trim cache size to 50MB when creating since it defaults to 50MB in the init, and immediately trims cache in[self initializeDiskProperties];
. This is obviously not ideal since if we specify a cache size >50MB then we will constantly be having to refetch assets on each app open since it will trim to 50MB each time.Proposed fix:
byteLimit
andageLimit