From e075134ffc94fda3582b179122bda594d91a962b Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Sat, 15 Oct 2022 11:52:07 +0200 Subject: wallet-core: simplify coin record we only track the allocation now, not the remaining amount --- packages/taler-util/src/backup-types.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'packages/taler-util/src/backup-types.ts') diff --git a/packages/taler-util/src/backup-types.ts b/packages/taler-util/src/backup-types.ts index 6c7b203b5..5d53f178e 100644 --- a/packages/taler-util/src/backup-types.ts +++ b/packages/taler-util/src/backup-types.ts @@ -475,6 +475,7 @@ export interface BackupRecoupGroup { timestamp_finish?: TalerProtocolTimestamp; finish_clock?: TalerProtocolTimestamp; + // FIXME: Use some enum here! finish_is_failure?: boolean; /** @@ -483,7 +484,6 @@ export interface BackupRecoupGroup { coins: { coin_pub: string; recoup_finished: boolean; - old_amount: BackupAmountString; }[]; } @@ -582,9 +582,14 @@ export interface BackupCoin { denom_sig: UnblindedSignature; /** - * Amount that's left on the coin. + * Information about where and how the coin was spent. */ - current_amount: BackupAmountString; + spend_allocation: + | { + id: string; + amount: BackupAmountString; + } + | undefined; /** * Blinding key used when withdrawing the coin. -- cgit v1.2.3