Commit 63658149 authored by Aleix Pol Gonzalez's avatar Aleix Pol Gonzalez 🐧
Browse files

flatpak: Some components have no releases

parent 47737ebd
Pipeline #222493 passed with stage
in 2 minutes and 26 seconds
......@@ -1393,7 +1393,10 @@ ResultsStream *FlatpakBackend::search(const AbstractResourcesBackend::Filters &f
for (auto ref : qAsConst(it.value())) {
bool fresh;
auto resource = getAppForInstalledRef(it.key(), ref, &fresh);
resource->setAvailableVersion(resource->appdata().releases().constFirst().version());
const auto releases = resource->appdata().releases();
if (!releases.isEmpty()) {
resource->setAvailableVersion(releases.constFirst().version());
}
g_object_unref(ref);
resource->setState(AbstractResource::Upgradeable, !fresh);
updateAppSize(resource);
......
Supports Markdown
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