summaryrefslogtreecommitdiff
path: root/src/backend/taler-merchant-httpd_private-get-products.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-04-20 22:15:25 +0200
committerChristian Grothoff <christian@grothoff.org>2020-04-20 22:15:25 +0200
commit4913f563537f78215b7512fad7f41ef971bc3e97 (patch)
tree6ea3211685029f63738a42f4dc2fc6574087a80e /src/backend/taler-merchant-httpd_private-get-products.c
parenta01d45c4f35aa5195af542cdc2244f4940667d21 (diff)
downloadmerchant-4913f563537f78215b7512fad7f41ef971bc3e97.tar.gz
merchant-4913f563537f78215b7512fad7f41ef971bc3e97.tar.bz2
merchant-4913f563537f78215b7512fad7f41ef971bc3e97.zip
work on /products and /instances C API
Diffstat (limited to 'src/backend/taler-merchant-httpd_private-get-products.c')
-rw-r--r--src/backend/taler-merchant-httpd_private-get-products.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/src/backend/taler-merchant-httpd_private-get-products.c b/src/backend/taler-merchant-httpd_private-get-products.c
index 21729a59..00b04636 100644
--- a/src/backend/taler-merchant-httpd_private-get-products.c
+++ b/src/backend/taler-merchant-httpd_private-get-products.c
@@ -27,14 +27,10 @@
*
* @param cls a `json_t *` JSON array to build
* @param product_id ID of the product
- * @param in_stock how many are currently in stock (possibly locked), -1 for infinite
- * @param unit in which unit is the stock measured in
*/
static void
add_product (void *cls,
- const char *product_id,
- long long in_stock,
- const char *unit)
+ const char *product_id)
{
json_t *pa = cls;
@@ -42,13 +38,9 @@ add_product (void *cls,
json_array_append_new (
pa,
json_pack (
- "{s:s, s:I, s:s}",
+ "{s:s}",
"product_id",
- product_id,
- "stock",
- (json_int_t) in_stock,
- "unit",
- unit)));
+ product_id)));
}