diff options
Diffstat (limited to 'src/backend/taler-merchant-httpd_private-get-templates-ID.c')
-rw-r--r-- | src/backend/taler-merchant-httpd_private-get-templates-ID.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/backend/taler-merchant-httpd_private-get-templates-ID.c b/src/backend/taler-merchant-httpd_private-get-templates-ID.c index a5b05f0c..35fdd1d0 100644 --- a/src/backend/taler-merchant-httpd_private-get-templates-ID.c +++ b/src/backend/taler-merchant-httpd_private-get-templates-ID.c @@ -61,15 +61,20 @@ TMH_private_get_templates_ID ( ret = TALER_MHD_REPLY_JSON_PACK ( connection, MHD_HTTP_OK, + GNUNET_JSON_pack_allow_null ( + GNUNET_JSON_pack_string ("required_currency", + tp.required_currency)), + GNUNET_JSON_pack_allow_null ( + GNUNET_JSON_pack_object_incref ("editable_defaults", + tp.editable_defaults)), GNUNET_JSON_pack_string ("template_description", tp.template_description), GNUNET_JSON_pack_allow_null ( GNUNET_JSON_pack_string ("otp_id", tp.otp_id)), - GNUNET_JSON_pack_object_steal ("template_contract", - tp.template_contract)); - GNUNET_free (tp.template_description); - GNUNET_free (tp.otp_id); + GNUNET_JSON_pack_object_incref ("template_contract", + tp.template_contract)); + TALER_MERCHANTDB_template_details_free (&tp); return ret; } } |