summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2020-07-06 10:52:24 +0200
committerChristian Grothoff <christian@grothoff.org>2020-07-06 10:52:24 +0200
commit85a02216d8a1926f2a528e0bae64c76410a6263d (patch)
treed7921409023cf2d1d167709dde543d851e83b8cb
parentd37e16a76c32e83407f5ea71e572cc5469a58924 (diff)
downloadmerchant-85a02216d8a1926f2a528e0bae64c76410a6263d.tar.gz
merchant-85a02216d8a1926f2a528e0bae64c76410a6263d.tar.bz2
merchant-85a02216d8a1926f2a528e0bae64c76410a6263d.zip
fix #5930
-rw-r--r--src/backend/taler-merchant-httpd_private-post-orders.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/backend/taler-merchant-httpd_private-post-orders.c b/src/backend/taler-merchant-httpd_private-post-orders.c
index 06fd562b..5ccad64d 100644
--- a/src/backend/taler-merchant-httpd_private-post-orders.c
+++ b/src/backend/taler-merchant-httpd_private-post-orders.c
@@ -673,9 +673,18 @@ patch_order (struct MHD_Connection *connection,
/* Fill in merchant information if necessary */
- if (NULL == json_object_get (order,
+ if (NULL != json_object_get (order,
"merchant"))
{
+ GNUNET_break_op (0);
+ return TALER_MHD_reply_with_error (
+ connection,
+ MHD_HTTP_BAD_REQUEST,
+ TALER_EC_PROPOSAL_ORDER_PARSE_ERROR,
+ "'merchant' field already set, but must be provided by backend");
+ }
+ else
+ {
const char *mj = NULL;
const char *ma = NULL;
json_t *locations;