diff options
author | Florian Dold <florian@dold.me> | 2023-09-08 13:33:21 +0200 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2023-09-08 13:33:21 +0200 |
commit | 4898f50db777a68cd2ddd0c1e323ef55033f4af7 (patch) | |
tree | 82b241ffc35413c6653d781e381f3d47f7ffd544 /packages/taler-wallet-core/src/operations/common.ts | |
parent | 2ae952cdfa8f38a650be8e4438c21bace2f24c19 (diff) | |
download | wallet-core-4898f50db777a68cd2ddd0c1e323ef55033f4af7.tar.xz |
wallet-core: more DB cleanup
Diffstat (limited to 'packages/taler-wallet-core/src/operations/common.ts')
-rw-r--r-- | packages/taler-wallet-core/src/operations/common.ts | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/packages/taler-wallet-core/src/operations/common.ts b/packages/taler-wallet-core/src/operations/common.ts index 680874dfa..50dd3dc5c 100644 --- a/packages/taler-wallet-core/src/operations/common.ts +++ b/packages/taler-wallet-core/src/operations/common.ts @@ -26,7 +26,6 @@ import { CoinRefreshRequest, CoinStatus, Duration, - ErrorInfoSummary, ExchangeEntryStatus, ExchangeListItem, ExchangeTosStatus, @@ -34,9 +33,11 @@ import { getErrorDetailFromException, j2s, Logger, + makeErrorDetail, NotificationType, OperationErrorInfo, RefreshReason, + TalerError, TalerErrorCode, TalerErrorDetail, TombstoneIdStr, @@ -44,32 +45,31 @@ import { TransactionType, WalletNotification, } from "@gnu-taler/taler-util"; +import { CryptoApiStoppedError } from "../crypto/workers/crypto-dispatcher.js"; import { - WalletStoresV1, + BackupProviderRecord, CoinRecord, + DepositGroupRecord, ExchangeDetailsRecord, + ExchangeEntryDbRecordStatus, + ExchangeEntryDbUpdateStatus, ExchangeEntryRecord, - BackupProviderRecord, - DepositGroupRecord, - PeerPullPaymentIncomingRecord, PeerPullCreditRecord, - PeerPushPaymentIncomingRecord, + PeerPullPaymentIncomingRecord, PeerPushDebitRecord, + PeerPushPaymentIncomingRecord, PurchaseRecord, RecoupGroupRecord, RefreshGroupRecord, RewardRecord, + WalletStoresV1, WithdrawalGroupRecord, - ExchangeEntryDbUpdateStatus, - ExchangeEntryDbRecordStatus, } from "../db.js"; -import { makeErrorDetail, TalerError } from "@gnu-taler/taler-util"; import { InternalWalletState } from "../internal-wallet-state.js"; -import { checkDbInvariant, checkLogicInvariant } from "../util/invariants.js"; -import { GetReadOnlyAccess, GetReadWriteAccess } from "../util/query.js"; -import { CryptoApiStoppedError } from "../crypto/workers/crypto-dispatcher.js"; import { PendingTaskType, TaskId } from "../pending-types.js"; import { assertUnreachable } from "../util/assertUnreachable.js"; +import { checkDbInvariant, checkLogicInvariant } from "../util/invariants.js"; +import { GetReadOnlyAccess, GetReadWriteAccess } from "../util/query.js"; import { constructTransactionIdentifier } from "./transactions.js"; const logger = new Logger("operations/common.ts"); @@ -144,8 +144,7 @@ export async function makeCoinAvailable( if (!car) { car = { maxAge: ageRestriction, - amountFrac: denom.amountFrac, - amountVal: denom.amountVal, + value: denom.value, currency: denom.currency, denomPubHash: denom.denomPubHash, exchangeBaseUrl: denom.exchangeBaseUrl, |