diff options
author | Florian Dold <florian@dold.me> | 2021-08-24 14:25:46 +0200 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2021-08-24 14:30:33 +0200 |
commit | 408d8e9fc896193fbcff1afd12aa04ab6d513798 (patch) | |
tree | a117a3c5d9130ea9b18c4198d3978f38dbd2f101 /packages/taler-wallet-core/src/operations/pending.ts | |
parent | 7553ae7c74bc04c268b77d010fb2f5b5eacad460 (diff) | |
download | wallet-core-408d8e9fc896193fbcff1afd12aa04ab6d513798.tar.xz |
towards handling frozen refreshes
Diffstat (limited to 'packages/taler-wallet-core/src/operations/pending.ts')
-rw-r--r-- | packages/taler-wallet-core/src/operations/pending.ts | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/packages/taler-wallet-core/src/operations/pending.ts b/packages/taler-wallet-core/src/operations/pending.ts index 200e6ccbd..a4ca972a7 100644 --- a/packages/taler-wallet-core/src/operations/pending.ts +++ b/packages/taler-wallet-core/src/operations/pending.ts @@ -27,6 +27,7 @@ import { AbortStatus, WalletStoresV1, BackupProviderStateTag, + RefreshCoinStatus, } from "../db.js"; import { PendingOperationsResponse, @@ -111,12 +112,17 @@ async function gatherRefreshPending( if (r.timestampFinished) { return; } + if (r.frozen) { + return; + } resp.pendingOperations.push({ type: PendingTaskType.Refresh, givesLifeness: true, timestampDue: r.retryInfo.nextRetry, refreshGroupId: r.refreshGroupId, - finishedPerCoin: r.finishedPerCoin, + finishedPerCoin: r.statusPerCoin.map( + (x) => x === RefreshCoinStatus.Finished, + ), retryInfo: r.retryInfo, }); }); |