[gnome-software/wip/ubuntu-3-22: 24/27] snap: Support new snapd license field
- From: Robert Ancell <rancell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software/wip/ubuntu-3-22: 24/27] snap: Support new snapd license field
- Date: Fri, 27 Oct 2017 04:01:42 +0000 (UTC)
commit 3d7b1e661772d51d577672e808c5b4161ff695ac
Author: Robert Ancell <robert ancell canonical com>
Date: Tue Sep 5 11:34:56 2017 +1200
snap: Support new snapd license field
src/plugins/gs-plugin-snap.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/plugins/gs-plugin-snap.c b/src/plugins/gs-plugin-snap.c
index d7d050b..049106b 100644
--- a/src/plugins/gs-plugin-snap.c
+++ b/src/plugins/gs-plugin-snap.c
@@ -552,6 +552,8 @@ gs_plugin_refine_app (GsPlugin *plugin,
gs_app_set_name (app, GS_APP_QUALITY_NORMAL, get_snap_title (local_snap));
gs_app_set_summary (app, GS_APP_QUALITY_NORMAL, json_object_get_string_member (local_snap,
"summary"));
gs_app_set_description (app, GS_APP_QUALITY_NORMAL, json_object_get_string_member
(local_snap, "description"));
+ if (json_object_has_member (local_snap, "license"))
+ gs_app_set_license (app, GS_APP_QUALITY_NORMAL, json_object_get_string_member
(local_snap, "license"));
gs_app_set_version (app, json_object_get_string_member (local_snap, "version"));
if (json_object_has_member (local_snap, "installed-size"))
gs_app_set_size_installed (app, json_object_get_int_member (local_snap,
"installed-size"));
@@ -584,6 +586,8 @@ gs_plugin_refine_app (GsPlugin *plugin,
gs_app_set_name (app, GS_APP_QUALITY_NORMAL, get_snap_title (store_snap));
gs_app_set_summary (app, GS_APP_QUALITY_NORMAL, json_object_get_string_member (store_snap,
"summary"));
gs_app_set_description (app, GS_APP_QUALITY_NORMAL, json_object_get_string_member
(store_snap, "description"));
+ if (json_object_has_member (store_snap, "license"))
+ gs_app_set_license (app, GS_APP_QUALITY_NORMAL, json_object_get_string_member
(store_snap, "license"));
gs_app_set_version (app, json_object_get_string_member (store_snap, "version"));
if (json_object_has_member (store_snap, "download-size"))
gs_app_set_size_download (app, json_object_get_int_member (store_snap,
"download-size"));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]