[gnome-software/wip/hughsie/unique-id-hash: 1/2] trivial: Copy the branch when refining from AppStream data



commit e32614f5a2224744079a6f897293b769affe90c9
Author: Richard Hughes <richard hughsie com>
Date:   Thu Aug 25 13:53:00 2016 +0100

    trivial: Copy the branch when refining from AppStream data

 src/plugins/gs-appstream.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/src/plugins/gs-appstream.c b/src/plugins/gs-appstream.c
index df2d91c..e139a51 100644
--- a/src/plugins/gs-appstream.c
+++ b/src/plugins/gs-appstream.c
@@ -531,6 +531,11 @@ gs_appstream_refine_app (GsPlugin *plugin,
            as_app_get_scope (item) != AS_APP_SCOPE_UNKNOWN)
                gs_app_set_scope (app, as_app_get_scope (item));
 
+       /* set branch */
+       if (as_app_get_branch (item) != NULL &&
+           gs_app_get_branch (app) == NULL)
+               gs_app_set_branch (app, as_app_get_branch (item));
+
        /* bundle-kind */
        if (gs_app_get_bundle_kind (app) == AS_BUNDLE_KIND_UNKNOWN)
                gs_app_set_bundle_kind (app, gs_appstream_get_bundle_kind (item));


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]