From d7364d0f28ff1ceadc92cd2b939aeecb76d986eb Mon Sep 17 00:00:00 2001 From: Wilmer Paulino Date: Tue, 3 Sep 2019 14:25:03 -0700 Subject: [PATCH] rpc: populate missing fields for waiting close channels --- rpcserver.go | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/rpcserver.go b/rpcserver.go index c6776ac1..c030c4c3 100644 --- a/rpcserver.go +++ b/rpcserver.go @@ -2356,10 +2356,13 @@ func (r *rpcServer) PendingChannels(ctx context.Context, pub := waitingClose.IdentityPub.SerializeCompressed() chanPoint := waitingClose.FundingOutpoint channel := &lnrpc.PendingChannelsResponse_PendingChannel{ - RemoteNodePub: hex.EncodeToString(pub), - ChannelPoint: chanPoint.String(), - Capacity: int64(waitingClose.Capacity), - LocalBalance: int64(waitingClose.LocalCommitment.LocalBalance.ToSatoshis()), + RemoteNodePub: hex.EncodeToString(pub), + ChannelPoint: chanPoint.String(), + Capacity: int64(waitingClose.Capacity), + LocalBalance: int64(waitingClose.LocalCommitment.LocalBalance.ToSatoshis()), + RemoteBalance: int64(waitingClose.LocalCommitment.RemoteBalance.ToSatoshis()), + LocalChanReserveSat: int64(waitingClose.LocalChanCfg.ChanReserve), + RemoteChanReserveSat: int64(waitingClose.RemoteChanCfg.ChanReserve), } // A close tx has been broadcasted, all our balance will be in