[gnome-software/wip/ubuntu-3-22: 29/33] 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: 29/33] snap: Support new snapd license field
- Date: Thu, 26 Oct 2017 21:44:08 +0000 (UTC)
commit 16f316d28b534cbdba68576267c7ca4da01fe514
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 fa7bb3b..bf87898 100644
--- a/src/plugins/gs-plugin-snap.c
+++ b/src/plugins/gs-plugin-snap.c
@@ -551,6 +551,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"));
@@ -583,6 +585,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]