rpcserver: remove redundant call to FetchInputInfo

This commit is contained in:
yyforyongyu 2024-08-01 03:08:56 +08:00
parent aba8507b2a
commit d7381ce3fe
No known key found for this signature in database
GPG key ID: 9BCD95C4FF296868

View file

@ -3488,14 +3488,7 @@ func (r *rpcServer) WalletBalance(ctx context.Context,
return nil, err
}
for _, leasedOutput := range leases {
utxoInfo, err := r.server.cc.Wallet.FetchInputInfo(
&leasedOutput.Outpoint,
)
if err != nil {
return nil, err
}
lockedBalance += utxoInfo.Value
lockedBalance += btcutil.Amount(leasedOutput.Value)
}
// Get the current number of non-private anchor channels.