final BitmapLruCache.Builder builder = new BitmapLruCache.Builder(context.getApplicationContext());
builder.setMemoryCacheEnabled(true).setMemoryCacheMaxSizeUsingHeapSize();
builder.setDiskCacheEnabled(true).setDiskCacheLocation(cacheLocation)
.setRecyclePolicy(RecyclePolicy.DISABLED);
this.imageCache = builder.build();
Sometimes it fails at the last line which I think is wrong. It should just gracefully disable SD caching if the error is caught
Here's stack trace
java.lang.IllegalArgumentException: Disk Cache Location is not write-able
at uk.co.senab.bitmapcache.BitmapLruCache$Builder.isValidOptionsForDiskCache(BitmapLruCache.java:737)
at uk.co.senab.bitmapcache.BitmapLruCache$Builder.build(BitmapLruCache.java:614)
I have this piece of code to init image cache
Sometimes it fails at the last line which I think is wrong. It should just gracefully disable SD caching if the error is caught
Here's stack trace