aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-wallet-core/src/operations/withdraw.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2022-09-20 21:44:21 +0200
committerFlorian Dold <florian@dold.me>2022-09-20 23:17:42 +0200
commit16a5bb40834c01e50e84144bb644517e67a66187 (patch)
treef6e7167aca608316ad03cf1e0debdb65eabe02cc /packages/taler-wallet-core/src/operations/withdraw.ts
parent52ec740c825d4e94fd59ef0a5cd8e8b73f4dfc06 (diff)
downloadwallet-core-16a5bb40834c01e50e84144bb644517e67a66187.tar.xz
wallet-core: make basic backup work again
Diffstat (limited to 'packages/taler-wallet-core/src/operations/withdraw.ts')
-rw-r--r--packages/taler-wallet-core/src/operations/withdraw.ts7
1 files changed, 5 insertions, 2 deletions
diff --git a/packages/taler-wallet-core/src/operations/withdraw.ts b/packages/taler-wallet-core/src/operations/withdraw.ts
index de9721f3d..7dd874f49 100644
--- a/packages/taler-wallet-core/src/operations/withdraw.ts
+++ b/packages/taler-wallet-core/src/operations/withdraw.ts
@@ -96,12 +96,13 @@ import { DbAccess, GetReadOnlyAccess } from "../util/query.js";
import {
OperationAttemptResult,
OperationAttemptResultType,
+ RetryTags,
} from "../util/retries.js";
import {
WALLET_BANK_INTEGRATION_PROTOCOL_VERSION,
WALLET_EXCHANGE_PROTOCOL_VERSION,
} from "../versions.js";
-import { makeCoinAvailable } from "../wallet.js";
+import { makeCoinAvailable, storeOperationPending } from "../wallet.js";
import {
getExchangeDetails,
getExchangePaytoUri,
@@ -1099,6 +1100,7 @@ export async function processWithdrawalGroup(
);
if (withdrawalGroup.denomsSel.selectedDenoms.length === 0) {
+ logger.warn("Finishing empty withdrawal group (no denoms)");
await ws.db
.mktx((x) => [x.withdrawalGroups])
.runReadWrite(async (tx) => {
@@ -1107,6 +1109,7 @@ export async function processWithdrawalGroup(
return;
}
wg.operationStatus = OperationStatus.Finished;
+ wg.timestampFinish = TalerProtocolTimestamp.now();
await tx.withdrawalGroups.put(wg);
});
return {
@@ -1185,7 +1188,7 @@ export async function processWithdrawalGroup(
errorsPerCoin[x.coinIdx] = x.lastError;
}
});
- logger.trace(`now withdrawn ${numFinished} of ${numTotalCoins} coins`);
+ logger.info(`now withdrawn ${numFinished} of ${numTotalCoins} coins`);
if (wg.timestampFinish === undefined && numFinished === numTotalCoins) {
finishedForFirstTime = true;
wg.timestampFinish = TalerProtocolTimestamp.now();