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

fwupd: don't show an error message when there's no updates

It's perfectly fine when a device is already up to date
parent 8173372a
......@@ -253,16 +253,7 @@ void FwupdBackend::addUpdates()
g_autoptr(GPtrArray) rels = fwupd_client_get_upgrades(client, fwupd_device_get_id(device), nullptr, &error2);
if (!rels)
{
if (g_error_matches(error2, FWUPD_ERROR, FWUPD_ERROR_NOTHING_TO_DO))
{
qWarning() << "Fwupd Error: No Packages Found for "<< fwupd_device_get_id(device) << fwupd_device_get_name(device);
handleError(&error2);
continue;
}
}
else
if (rels)
{
fwupd_device_add_release(device,(FwupdRelease *)g_ptr_array_index(rels, 0));
auto res = createApp(device);
......@@ -287,6 +278,11 @@ void FwupdBackend::addUpdates()
}
addResourceToList(res);
}
} else {
if (!g_error_matches(error2, FWUPD_ERROR, FWUPD_ERROR_NOTHING_TO_DO))
{
handleError(&error2);
}
}
}
}
......
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