mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2024-11-22 20:48:00 +01:00
fix #1153, do not show favorite items from hidden folders, when shouldnt
This commit is contained in:
parent
a608ce2d6e
commit
5abb3ae538
1 changed files with 6 additions and 6 deletions
|
@ -182,16 +182,16 @@ class MediaFetcher(val context: Context) {
|
|||
ArrayList()
|
||||
}
|
||||
|
||||
val files = when (folder) {
|
||||
FAVORITES -> favoritePaths.map { File(it) }.toTypedArray()
|
||||
RECYCLE_BIN -> deletedMedia.map { File(it.path) }.toTypedArray()
|
||||
else -> File(folder).listFiles() ?: return media
|
||||
}
|
||||
|
||||
val doExtraCheck = context.config.doExtraCheck
|
||||
val showHidden = context.config.shouldShowHidden
|
||||
val dateTakens = if (getProperDateTaken) getFolderDateTakens(folder) else HashMap()
|
||||
|
||||
val files = when (folder) {
|
||||
FAVORITES -> favoritePaths.filter { showHidden || !it.contains("/.") }.map { File(it) }.toTypedArray()
|
||||
RECYCLE_BIN -> deletedMedia.map { File(it.path) }.toTypedArray()
|
||||
else -> File(folder).listFiles() ?: return media
|
||||
}
|
||||
|
||||
for (file in files) {
|
||||
if (shouldStop) {
|
||||
break
|
||||
|
|
Loading…
Reference in a new issue