diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/Utils.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/Utils.kt index afa291954..2b9d746d7 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/Utils.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/Utils.kt @@ -111,10 +111,7 @@ class Utils { } } - fun isAStorageRootFolder(context: Context, path: String): Boolean { - val trimmed = path.trimEnd('/') - return trimmed.isEmpty() || trimmed == context.getInternalStoragePath() || trimmed == context.getSDCardPath() - } + fun isAStorageRootFolder(context: Context, path: String) = context.isAStorageRootFolder(path) fun isPhotoVideo(file: File) = file.isPhotoVideo()