Fix mangadex group deeplink not only searching mangadex sources

This commit is contained in:
Jobobby04 2022-10-08 19:00:02 -04:00
parent 17bb5d1c4b
commit 39c82feb01

View File

@ -116,11 +116,13 @@ open class GlobalSearchPresenter(
var filteredSources: List<CatalogueSource>? = null
if (!filter.isNullOrEmpty()) {
filteredSources = extensionManager.installedExtensions
// SY -->
val filteredSourceIds = extensionManager.installedExtensions
.filter { it.pkgName == filter }
.flatMap { it.sources }
.filter { it in enabledSources }
.filterIsInstance<CatalogueSource>()
.map { it.id }
filteredSources = enabledSources.filter { it.id in filteredSourceIds }
// SY <--
}
if (filteredSources != null && filteredSources.isNotEmpty()) {