summaryrefslogtreecommitdiff
path: root/packages/taler-wallet-core/src/common.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2024-02-19 18:42:33 +0100
committerFlorian Dold <florian@dold.me>2024-02-19 18:42:33 +0100
commiteb1500e517d475aad22cfe02c8a5c5c6acefe00a (patch)
tree4572e0f8437fae4de6d6d7dade2c874af95769f2 /packages/taler-wallet-core/src/common.ts
parente888d7f292f68a58fc4b56771fb8a38219d53b86 (diff)
downloadwallet-core-eb1500e517d475aad22cfe02c8a5c5c6acefe00a.tar.gz
wallet-core-eb1500e517d475aad22cfe02c8a5c5c6acefe00a.tar.bz2
wallet-core-eb1500e517d475aad22cfe02c8a5c5c6acefe00a.zip
get rid of deprecated/unused types
Diffstat (limited to 'packages/taler-wallet-core/src/common.ts')
-rw-r--r--packages/taler-wallet-core/src/common.ts28
1 files changed, 26 insertions, 2 deletions
diff --git a/packages/taler-wallet-core/src/common.ts b/packages/taler-wallet-core/src/common.ts
index ae1e17ffb..9d7f2e763 100644
--- a/packages/taler-wallet-core/src/common.ts
+++ b/packages/taler-wallet-core/src/common.ts
@@ -58,10 +58,9 @@ import {
timestampPreciseToDb,
} from "./db.js";
import { InternalWalletState } from "./internal-wallet-state.js";
-import { PendingTaskType, TaskId } from "./pending-types.js";
+import { createRefreshGroup } from "./refresh.js";
import { assertUnreachable } from "./util/assertUnreachable.js";
import { checkDbInvariant, checkLogicInvariant } from "./util/invariants.js";
-import { createRefreshGroup } from "./refresh.js";
const logger = new Logger("operations/common.ts");
@@ -691,3 +690,28 @@ export interface TransactionContext {
failTransaction(): Promise<void>;
deleteTransaction(): Promise<void>;
}
+
+/**
+ * Type and schema definitions for pending tasks in the wallet.
+ *
+ * These are only used internally, and are not part of the stable public
+ * interface to the wallet.
+ */
+
+export enum PendingTaskType {
+ ExchangeUpdate = "exchange-update",
+ Purchase = "purchase",
+ Refresh = "refresh",
+ Recoup = "recoup",
+ RewardPickup = "reward-pickup",
+ Withdraw = "withdraw",
+ Deposit = "deposit",
+ Backup = "backup",
+ PeerPushDebit = "peer-push-debit",
+ PeerPullCredit = "peer-pull-credit",
+ PeerPushCredit = "peer-push-credit",
+ PeerPullDebit = "peer-pull-debit",
+}
+
+declare const __taskId: unique symbol;
+export type TaskId = string & { [__taskId]: true };