From 4d016a9e096768b0a3e1592aa30c69b4e465266d Mon Sep 17 00:00:00 2001 From: tibbi Date: Tue, 10 Sep 2019 09:34:49 +0200 Subject: [PATCH] fixing an error with no folders for scanning --- .../com/simplemobiletools/gallery/pro/helpers/MediaFetcher.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/pro/helpers/MediaFetcher.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/pro/helpers/MediaFetcher.kt index 8d381eeed..c87341fca 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/pro/helpers/MediaFetcher.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/pro/helpers/MediaFetcher.kt @@ -178,7 +178,7 @@ class MediaFetcher(val context: Context) { val showHidden = config.shouldShowHidden val excludedFolders = config.excludedFolders foldersToScan = foldersToScan.filter { it.shouldFolderBeVisible(excludedFolders, includedFolders, showHidden) } as ArrayList - return foldersToScan.distinctBy { it.getDistinctPath() }.toSet() as LinkedHashSet + return foldersToScan.distinctBy { it.getDistinctPath() }.toMutableSet() as LinkedHashSet } private fun addFolder(curFolders: ArrayList, folder: String) {