gnunet-svn
[Top][All Lists]
Advanced

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

[taler-wallet-core] branch master updated: repuchase detected previous u


From: gnunet
Subject: [taler-wallet-core] branch master updated: repuchase detected previous unpaid purchased
Date: Fri, 23 Feb 2024 16:42:27 +0100

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

sebasjm pushed a commit to branch master
in repository wallet-core.

The following commit(s) were added to refs/heads/master by this push:
     new 467eb5e09 repuchase detected previous unpaid purchased
467eb5e09 is described below

commit 467eb5e090bbce7436bd4eb41902d19235da4dba
Author: Sebastian <sebasjm@gmail.com>
AuthorDate: Fri Feb 23 12:42:21 2024 -0300

    repuchase detected previous unpaid purchased
---
 packages/taler-wallet-core/src/pay-merchant.ts | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/packages/taler-wallet-core/src/pay-merchant.ts 
b/packages/taler-wallet-core/src/pay-merchant.ts
index 09e9e1fb3..adc8b42e9 100644
--- a/packages/taler-wallet-core/src/pay-merchant.ts
+++ b/packages/taler-wallet-core/src/pay-merchant.ts
@@ -828,7 +828,9 @@ async function processDownloadProposal(
       }
       // FIXME: Adjust this to account for refunds, don't count as repurchase
       // if original order is refunded.
-      if (otherPurchase && otherPurchase.refundAmountAwaiting === undefined) {
+      if (otherPurchase && (otherPurchase.purchaseStatus == PurchaseStatus.Done
+        || otherPurchase.purchaseStatus == PurchaseStatus.PendingPaying
+        || otherPurchase.purchaseStatus == 
PurchaseStatus.PendingPayingReplay)) {
         logger.warn("repurchase detected");
         p.purchaseStatus = PurchaseStatus.DoneRepurchaseDetected;
         p.repurchaseProposalId = otherPurchase.proposalId;
@@ -1719,7 +1721,7 @@ async function internalWaitPaymentResult(
       };
     }
 
-    if (txRes.purchase.purchaseStatus > PurchaseStatus.Done) {
+    if (txRes.purchase.purchaseStatus >= PurchaseStatus.Done) {
       return {
         type: ConfirmPayResultType.Done,
         contractTerms: d.contractTermsRaw,

-- 
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]