diff options
Diffstat (limited to 'src/backend/taler-merchant-httpd_post-orders-ID-refund.c')
-rw-r--r-- | src/backend/taler-merchant-httpd_post-orders-ID-refund.c | 26 |
1 files changed, 8 insertions, 18 deletions
diff --git a/src/backend/taler-merchant-httpd_post-orders-ID-refund.c b/src/backend/taler-merchant-httpd_post-orders-ID-refund.c index 40c89712..766c8814 100644 --- a/src/backend/taler-merchant-httpd_post-orders-ID-refund.c +++ b/src/backend/taler-merchant-httpd_post-orders-ID-refund.c @@ -386,17 +386,14 @@ notify_refund_obtained (struct PostRefundData *prd) * refund request to an exchange. * * @param cls a `struct CoinRefund` - * @param hr HTTP response data - * @param exchange_pub exchange key used to sign refund confirmation - * @param exchange_sig exchange's signature over refund + * @param rr response data */ static void refund_cb (void *cls, - const struct TALER_EXCHANGE_HttpResponse *hr, - const struct TALER_ExchangePublicKeyP *exchange_pub, - const struct TALER_ExchangeSignatureP *exchange_sig) + const struct TALER_EXCHANGE_RefundResponse *rr) { struct CoinRefund *cr = cls; + const struct TALER_EXCHANGE_HttpResponse *hr = &rr->hr; cr->rh = NULL; cr->exchange_status = hr->http_status; @@ -413,12 +410,12 @@ refund_cb (void *cls, { enum GNUNET_DB_QueryStatus qs; - cr->exchange_pub = *exchange_pub; - cr->exchange_sig = *exchange_sig; + cr->exchange_pub = rr->details.ok.exchange_pub; + cr->exchange_sig = rr->details.ok.exchange_sig; qs = TMH_db->insert_refund_proof (TMH_db->cls, cr->refund_serial, - exchange_sig, - exchange_pub); + &rr->details.ok.exchange_sig, + &rr->details.ok.exchange_pub); if (0 >= qs) { /* generally, this is relatively harmless for the merchant, but let's at @@ -443,23 +440,17 @@ refund_cb (void *cls, * @param cls a `struct CoinRefund *` * @param hr HTTP response details * @param eh handle to the exchange context - * @param payto_uri payto://-URI of the exchange - * @param wire_fee current applicable wire fee for dealing with @a eh, NULL if not available * @param exchange_trusted true if this exchange is trusted by config */ static void exchange_found_cb (void *cls, const struct TALER_EXCHANGE_HttpResponse *hr, struct TALER_EXCHANGE_Handle *eh, - const char *payto_uri, - const struct TALER_Amount *wire_fee, bool exchange_trusted) { struct CoinRefund *cr = cls; struct PostRefundData *prd = cr->prd; - (void) payto_uri; - (void) wire_fee; (void) exchange_trusted; cr->fo = NULL; if (NULL == hr) @@ -725,8 +716,7 @@ TMH_post_orders_ID_refund (const struct TMH_RequestHandler *rh, { /* We need to talk to the exchange */ cr->fo = TMH_EXCHANGES_find_exchange (cr->exchange_url, - NULL, - GNUNET_NO, + false, &exchange_found_cb, cr); } |