Commit 40a9fd65 authored by Aleix Pol Gonzalez's avatar Aleix Pol Gonzalez 🐧

Fix looking for popular applications by appstream id

When looking for an appstream id that is reported times, just show the
first that is offered, the user will choose among the sources.
It doesn't make any sense to fail because there's several.
parent 97a05430
......@@ -241,7 +241,7 @@ void DiscoverObject::openApplication(const QUrl& url)
auto stream = new StoredResultsStream({ResourcesModel::global()->search(f)});
connect(stream, &StoredResultsStream::finished, this, [this, url, stream]() {
const auto res = stream->resources();
if (res.count() == 1) {
if (res.count() >= 1) {
emit openApplicationInternal(res.first());
} else {
setRootObjectProperty("defaultStartup", true);
......
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