From 97436ba0044d3cad434f90618558b6ff01e55566 Mon Sep 17 00:00:00 2001 From: tibbi Date: Wed, 4 Mar 2020 14:44:27 +0100 Subject: [PATCH] breaking an if/else statement into multiple lines --- .../com/simplemobiletools/gallery/pro/extensions/String.kt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) 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)) {