From b5e1ea4d574b12e09d3b637cc5d91387553c4d9f Mon Sep 17 00:00:00 2001 From: Pietralberto Mazza <18440657+altafan@users.noreply.github.com> Date: Mon, 2 Sep 2024 23:24:12 +0200 Subject: [PATCH] Add SpentBy field to client.Vtxo (#285) --- pkg/client-sdk/client/client.go | 1 + pkg/client-sdk/client/grpc/client.go | 1 + pkg/client-sdk/client/rest/client.go | 2 ++ 3 files changed, 4 insertions(+) diff --git a/pkg/client-sdk/client/client.go b/pkg/client-sdk/client/client.go index c6b30c5bc..2280da6c6 100644 --- a/pkg/client-sdk/client/client.go +++ b/pkg/client-sdk/client/client.go @@ -81,6 +81,7 @@ type Vtxo struct { RedeemTx string UnconditionalForfeitTxs []string Pending bool + SpentBy string } type Output struct { diff --git a/pkg/client-sdk/client/grpc/client.go b/pkg/client-sdk/client/grpc/client.go index 1ab1dd308..11bb0f2e4 100644 --- a/pkg/client-sdk/client/grpc/client.go +++ b/pkg/client-sdk/client/grpc/client.go @@ -427,6 +427,7 @@ func (v vtxo) toVtxo() client.Vtxo { Pending: v.GetPending(), RedeemTx: redeemTx, UnconditionalForfeitTxs: uncondForfeitTxs, + SpentBy: v.GetSpentBy(), } } diff --git a/pkg/client-sdk/client/rest/client.go b/pkg/client-sdk/client/rest/client.go index 98c4ef278..718b8c626 100644 --- a/pkg/client-sdk/client/rest/client.go +++ b/pkg/client-sdk/client/rest/client.go @@ -168,6 +168,7 @@ func (a *restClient) ListVtxos( Pending: v.Pending, RedeemTx: redeemTx, UnconditionalForfeitTxs: uncondForfeitTxs, + SpentBy: v.SpentBy, }) } @@ -196,6 +197,7 @@ func (a *restClient) ListVtxos( Amount: uint64(amount), RoundTxid: v.PoolTxid, ExpiresAt: expiresAt, + SpentBy: v.SpentBy, }) }