aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-wallet-core/src/operations/refresh.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2022-09-16 17:35:06 +0200
committerFlorian Dold <florian@dold.me>2022-09-16 17:35:06 +0200
commit183c83661454cfb75ee6d2969b7529619d9a6226 (patch)
tree3494f517161f0093bfffd51b6f259fdd689c38e2 /packages/taler-wallet-core/src/operations/refresh.ts
parent16e7814445d57c2494ddaf3aaf11d60abb2b036b (diff)
downloadwallet-core-183c83661454cfb75ee6d2969b7529619d9a6226.tar.xz
-wallet-core: merge DenominationInfo and DenomInfo
Diffstat (limited to 'packages/taler-wallet-core/src/operations/refresh.ts')
-rw-r--r--packages/taler-wallet-core/src/operations/refresh.ts13
1 files changed, 7 insertions, 6 deletions
diff --git a/packages/taler-wallet-core/src/operations/refresh.ts b/packages/taler-wallet-core/src/operations/refresh.ts
index 048ab15b3..eeb492499 100644
--- a/packages/taler-wallet-core/src/operations/refresh.ts
+++ b/packages/taler-wallet-core/src/operations/refresh.ts
@@ -25,6 +25,7 @@ import {
codecForExchangeRevealResponse,
CoinPublicKey,
CoinPublicKeyString,
+ DenominationInfo,
DenomKeyType,
Duration,
durationFromSpec,
@@ -42,7 +43,6 @@ import {
NotificationType,
RefreshGroupId,
RefreshReason,
- TalerErrorDetail,
TalerProtocolTimestamp,
URL,
} from "@gnu-taler/taler-util";
@@ -64,7 +64,6 @@ import {
} from "../db.js";
import { TalerError } from "../errors.js";
import {
- DenomInfo,
EXCHANGE_COINS_LOCK,
InternalWalletState,
} from "../internal-wallet-state.js";
@@ -74,9 +73,11 @@ import {
} from "../util/http.js";
import { checkDbInvariant } from "../util/invariants.js";
import { GetReadWriteAccess } from "../util/query.js";
-import { OperationAttemptResult, OperationAttemptResultType, RetryInfo, runOperationHandlerForResult } from "../util/retries.js";
-import { makeCoinAvailable, Wallet } from "../wallet.js";
-import { guardOperationException } from "./common.js";
+import {
+ OperationAttemptResult,
+ OperationAttemptResultType,
+} from "../util/retries.js";
+import { makeCoinAvailable } from "../wallet.js";
import { updateExchangeFromUrl } from "./exchanges.js";
import {
isWithdrawableDenom,
@@ -98,7 +99,7 @@ const logger = new Logger("refresh.ts");
*/
export function getTotalRefreshCost(
denoms: DenominationRecord[],
- refreshedDenom: DenomInfo,
+ refreshedDenom: DenominationInfo,
amountLeft: AmountJson,
): AmountJson {
const withdrawAmount = Amounts.sub(