[gnome-software/gnome-3-30] generic updates: Fix old updates accumulating in the OS Updates item
- From: Kalev Lember <klember src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/gnome-3-30] generic updates: Fix old updates accumulating in the OS Updates item
- Date: Tue, 18 Dec 2018 01:14:33 +0000 (UTC)
commit 58100aa97a613a0cdf32e319378969ea2f771c75
Author: Kalev Lember <klember redhat com>
Date: Tue Dec 18 01:34:11 2018 +0100
generic updates: Fix old updates accumulating in the OS Updates item
When we first get an update to version 1, and a while later to version 2
of the same app, both of them would accumulate in the "OS Updates" item.
This was due to the use of plugin cache in the generic updates plugin
which kept the "OS Updates" from a previous get_updates call still
around and never removed the old apps from it.
Fix this by changing it to create a new "OS Updates" proxy app every
time.
https://bugzilla.redhat.com/show_bug.cgi?id=1642878
plugins/core/gs-plugin-generic-updates.c | 6 ------
1 file changed, 6 deletions(-)
---
diff --git a/plugins/core/gs-plugin-generic-updates.c b/plugins/core/gs-plugin-generic-updates.c
index 074ac1d8..866d0bae 100644
--- a/plugins/core/gs-plugin-generic-updates.c
+++ b/plugins/core/gs-plugin-generic-updates.c
@@ -55,11 +55,6 @@ gs_plugin_generic_updates_get_os_update (GsPlugin *plugin)
const gchar *id = "org.gnome.Software.OsUpdate";
g_autoptr(AsIcon) ic = NULL;
- /* look in cache */
- app = gs_plugin_cache_lookup (plugin, id);
- if (app != NULL)
- return app;
-
/* create new */
app = gs_app_new (id);
gs_app_add_quirk (app, AS_APP_QUIRK_IS_PROXY);
@@ -83,7 +78,6 @@ gs_plugin_generic_updates_get_os_update (GsPlugin *plugin)
as_icon_set_kind (ic, AS_ICON_KIND_STOCK);
as_icon_set_name (ic, "software-update-available-symbolic");
gs_app_add_icon (app, ic);
- gs_plugin_cache_add (plugin, id, app);
return app;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]