Commit 11d79794 authored by Nate Graham's avatar Nate Graham 💤
Browse files

Perform KNS searches from the Featured page again

Summary:
We previously disabled this in https://bugs.kde.org/show_bug.cgi?id=399503 to improve
the relevancy of the search results. However since then, searching has been improved in
various other ways. For example, exact title matches are now shown first, and apps are
shown before KNS entries. Therefore, it seems reasonable to re-enable KNS searches from
the Featured page.

BUG: 413880
FIXED-IN: 5.18.0

Test Plan: Can now find "Fokus" from a search inittated while viewing the Featured page.

Reviewers: apol, #discover_software_store

Subscribers: aspotashev, plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D25196
parent aa5e8077
......@@ -504,7 +504,7 @@ ResultsStream* KNSBackend::search(const AbstractResourcesBackend::Filters& filte
}
return stream;
} else if ((m_hasApplications && !filter.category) // If there is no category defined, we are searching in the root, and should include only application results
} else if ((!filter.category && !filter.search.isEmpty()) // Accept global searches
// If there /is/ a category, make sure we actually are one of those requested before searching
|| (filter.category && kContains(m_categories, [&filter](const QString& cat) { return filter.category->matchesCategoryName(cat); }))) {
auto r = new ResultsStream(QLatin1String("KNS-search-")+name());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment