diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetDirectoriesAsynctask.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetDirectoriesAsynctask.kt index a3fca44ca..5d10d9430 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetDirectoriesAsynctask.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetDirectoriesAsynctask.kt @@ -54,7 +54,7 @@ class GetDirectoriesAsynctask(val context: Context, val isPickVideo: Boolean, va val file = File(fullPath) val size = cursor.getLongValue(MediaStore.Images.Media.SIZE) - if (size == 0L || !file.exists()) { + if (size == 0L) { invalidFiles.add(file) continue } diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetMediaAsynctask.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetMediaAsynctask.kt index c2817cdbd..0c22e0c93 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetMediaAsynctask.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/asynctasks/GetMediaAsynctask.kt @@ -55,7 +55,7 @@ class GetMediaAsynctask(val context: Context, val mPath: String, val isPickVideo val file = File(curPath) val size = cursor.getLongValue(MediaStore.Images.Media.SIZE) - if (size == 0L || !file.exists()) { + if (size == 0L) { invalidFiles.add(file) continue }