diff --git a/library/src/main/java/com/mux/player/internal/cache/CacheDatastore.kt b/library/src/main/java/com/mux/player/internal/cache/CacheDatastore.kt index 3eb2ab0..f161d85 100644 --- a/library/src/main/java/com/mux/player/internal/cache/CacheDatastore.kt +++ b/library/src/main/java/com/mux/player/internal/cache/CacheDatastore.kt @@ -51,6 +51,8 @@ internal class CacheDatastore( fun open() { synchronized(dbGuard) { if (dbHelper == null) { + clearTempFiles() + ensureDirs() val newHelper = DbHelper(context.applicationContext, indexDbDir()) // acquire an extra reference until closed. prevents DB underneath from closing/reopening