gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-docs] branch master updated: allow h_contract as auth once order


From: gnunet
Subject: [taler-docs] branch master updated: allow h_contract as auth once order is claimed
Date: Sun, 08 Aug 2021 18:38:23 +0200

This is an automated email from the git hooks/post-receive script.

dold pushed a commit to branch master
in repository docs.

The following commit(s) were added to refs/heads/master by this push:
     new 45c5cae  allow h_contract as auth once order is claimed
45c5cae is described below

commit 45c5cae232f6a9717590a9eae3474cee337cb3f4
Author: Florian Dold <florian@dold.me>
AuthorDate: Sun Aug 8 18:38:18 2021 +0200

    allow h_contract as auth once order is claimed
---
 merchant-spec/public-orders-get.ts | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/merchant-spec/public-orders-get.ts 
b/merchant-spec/public-orders-get.ts
index 20b893a..225cc25 100644
--- a/merchant-spec/public-orders-get.ts
+++ b/merchant-spec/public-orders-get.ts
@@ -65,7 +65,8 @@ function handlePublicOrdersGet(mos: MerchantOrderStore, req: 
Req): Resp {
   }
 
   if (!ord.paid) {
-    if (ord.requireClaimToken && ord.claimToken !== req.claimToken) {
+    const hcOk = ord.contractHash === req.contractHash;
+    if (!hcOk && ord.requireClaimToken && ord.claimToken !== req.claimToken) {
       // This can happen when the fulfillment URL page detects
       // the user has not paid under the current session.
       return {
@@ -109,8 +110,8 @@ function handlePublicOrdersGet(mos: MerchantOrderStore, 
req: Req): Resp {
           responseType: "StatusGotoResponse",
           response: {
             already_paid_order_id: alreadyPaidOrd.orderId,
-          }
-        }
+          },
+        };
       }
       return {
         httpStatus: "402 Payment Required",

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]