[gnome-software] trivial: trigger the symlink rebuild after updating flatpak AppStream metadata
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] trivial: trigger the symlink rebuild after updating flatpak AppStream metadata
- Date: Fri, 10 Jun 2016 15:52:11 +0000 (UTC)
commit 9b891d3dd9734efb044de4a46aca8bd54e0044d8
Author: Richard Hughes <richard hughsie com>
Date: Fri Jun 10 16:51:45 2016 +0100
trivial: trigger the symlink rebuild after updating flatpak AppStream metadata
src/plugins/gs-flatpak.c | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/src/plugins/gs-flatpak.c b/src/plugins/gs-flatpak.c
index ea40bf0..c24ced1 100644
--- a/src/plugins/gs-flatpak.c
+++ b/src/plugins/gs-flatpak.c
@@ -124,6 +124,7 @@ gs_flatpak_refresh_appstream (GsFlatpak *self, guint cache_age,
GCancellable *cancellable, GError **error)
{
gboolean ret;
+ gboolean something_changed = FALSE;
guint i;
g_autoptr(GPtrArray) xremotes = NULL;
@@ -188,7 +189,20 @@ gs_flatpak_refresh_appstream (GsFlatpak *self, guint cache_age,
file = flatpak_remote_get_appstream_dir (xremote, NULL);
appstream_fn = g_file_get_path (file);
g_debug ("using AppStream metadata found at: %s", appstream_fn);
+
+ /* trigger the symlink rebuild */
+ something_changed = TRUE;
+ }
+
+ /* ensure the AppStream symlink cache is up to date */
+ if (something_changed) {
+ if (!gs_flatpak_symlinks_rebuild (self->installation,
+ cancellable,
+ error))
+ return FALSE;
+ gs_plugin_updates_changed (self->plugin);
}
+
return TRUE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]