app/src/main/java/fr/neamar/kiss/IconsHandler.java
// directly in ctx.getCacheDir() so we need to clean it
directly in ctx.getCacheDir() so we need to clean it
directly in ctx . getCacheDir () so we need to clean it
private void clearOldCache() {
        File newCacheDir = new File(this.ctx.getCacheDir(), "icons");
        if (!newCacheDir.isDirectory()) {
            File[] fileList = ctx.getCacheDir().listFiles();
            if (fileList != null) {
                int count = 0;
                for (File file : fileList) {
                    if (file.isFile())
                        count += file.delete() ? 1 : 0;
                }
                Log.i(TAG, "Removed " + count + " cache file(s) from the old path");
            }
        }
    }
private void clearOldCache ( ) { File newCacheDir = new File ( this . ctx . getCacheDir ( ) , "icons" ) ; if ( ! newCacheDir . isDirectory ( ) ) { File [ ] fileList = ctx . getCacheDir ( ) . listFiles ( ) ; if ( fileList != null ) { int count = 0 ; for ( File file : fileList ) { if ( file . isFile ( ) ) count += file . delete ( ) ? 1 : 0 ; } Log . i ( TAG , "Removed " + count + " cache file(s) from the old path" ) ; } } }
directly in ctx.getCacheDir() so we need to clean it
directly in ctx . getCacheDir () so we need to clean it