gnunet-svn
[Top][All Lists]
Advanced

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

[taler-wallet-core] branch master updated: reset reserve retry timeout w


From: gnunet
Subject: [taler-wallet-core] branch master updated: reset reserve retry timeout when forcing operation
Date: Wed, 22 Jan 2020 16:00:54 +0100

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

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

The following commit(s) were added to refs/heads/master by this push:
     new a6006178 reset reserve retry timeout when forcing operation
a6006178 is described below

commit a60061788fc9fd0cc60472db5e3ef68d34854441
Author: Florian Dold <address@hidden>
AuthorDate: Wed Jan 22 16:00:49 2020 +0100

    reset reserve retry timeout when forcing operation
---
 src/operations/reserves.ts | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/src/operations/reserves.ts b/src/operations/reserves.ts
index 7f5c7d05..463b57b6 100644
--- a/src/operations/reserves.ts
+++ b/src/operations/reserves.ts
@@ -61,6 +61,19 @@ import { getTimestampNow } from "../util/time";
 
 const logger = new Logger("reserves.ts");
 
+
+async function resetReserveRetry(
+  ws: InternalWalletState,
+  reservePub: string,
+) {
+  await ws.db.mutate(Stores.reserves, reservePub, x => {
+    if (x.retryInfo.active) {
+      x.retryInfo = initRetryInfo();
+    }
+    return x;
+  });
+}
+
 /**
  * Create a reserve, but do not flag it as confirmed yet.
  *
@@ -504,6 +517,8 @@ async function processReserveImpl(
       logger.trace("processReserve retry not due yet");
       return;
     }
+  } else {
+    await resetReserveRetry(ws, reservePub);
   }
   logger.trace(
     `Processing reserve ${reservePub} with status ${reserve.reserveStatus}`,

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

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