diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/dialogs/PickMediumDialog.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/dialogs/PickMediumDialog.kt index f89fae804..9d58425ce 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/dialogs/PickMediumDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/dialogs/PickMediumDialog.kt @@ -30,7 +30,8 @@ class PickMediumDialog(val activity: SimpleActivity, val path: String, val callb activity.setupDialogStuff(view, this, R.string.select_photo) val token = object : TypeToken>() {}.type - val media = Gson().fromJson>(activity.config.loadFolderMedia(path), token) ?: ArrayList(1) + var media = Gson().fromJson>(activity.config.loadFolderMedia(path), token) ?: ArrayList(1) + media = media.filter { !it.video } as ArrayList if (media.isNotEmpty()) { gotMedia(media)