diff --git a/lnwallet/btcwallet/psbt.go b/lnwallet/btcwallet/psbt.go index 7dbe12c2b..395c5667c 100644 --- a/lnwallet/btcwallet/psbt.go +++ b/lnwallet/btcwallet/psbt.go @@ -135,8 +135,9 @@ func (b *BtcWallet) SignPsbt(packet *psbt.Packet) ([]uint32, error) { var signedInputs []uint32 // Let's check that this is actually something we can and want to sign. - // We need at least one input and one output. - err := psbt.VerifyInputOutputLen(packet, true, true) + // We need at least one input and one output. In addition each + // input needs nonWitness Utxo or witness Utxo data specified. + err := psbt.InputsReadyToSign(packet) if err != nil { return nil, err } diff --git a/lnwallet/rpcwallet/rpcwallet.go b/lnwallet/rpcwallet/rpcwallet.go index 38f345c14..536ce6260 100644 --- a/lnwallet/rpcwallet/rpcwallet.go +++ b/lnwallet/rpcwallet/rpcwallet.go @@ -255,8 +255,9 @@ func (r *RPCKeyRing) SignPsbt(packet *psbt.Packet) ([]uint32, error) { // parameter in FinalizePsbt so we can get rid of this code duplication. func (r *RPCKeyRing) FinalizePsbt(packet *psbt.Packet, _ string) error { // Let's check that this is actually something we can and want to sign. - // We need at least one input and one output. - err := psbt.VerifyInputOutputLen(packet, true, true) + // We need at least one input and one output. In addition each + // input needs nonWitness Utxo or witness Utxo data specified. + err := psbt.InputsReadyToSign(packet) if err != nil { return err }