diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/pro/extensions/String.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/pro/extensions/String.kt index 3a8eb02ae..8d126a9db 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/pro/extensions/String.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/pro/extensions/String.kt @@ -32,7 +32,12 @@ fun String.shouldFolderBeVisible(excludedPaths: MutableSet, includedPath return true } - val containsNoMedia = if (showHidden) false else File(this, NOMEDIA).exists() + val containsNoMedia = if (showHidden) { + false + } else { + File(this, NOMEDIA).exists() + } + return if (!showHidden && containsNoMedia) { false } else if (excludedPaths.contains(this)) {