[gnome-software/wip/ubuntu-3-22: 1/2] 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: 1/2] snap: Support new snapd license field
- Date: Tue, 5 Sep 2017 04:37:06 +0000 (UTC)
commit c8622d5d2b8d8c24b5b3ae38ec7665b116a00ab6
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 46c9bdc..36a702d 100644
--- a/src/plugins/gs-plugin-snap.c
+++ b/src/plugins/gs-plugin-snap.c
@@ -529,6 +529,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"));
@@ -561,6 +563,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]