@@ -1890,7 +1890,7 @@ func newFundingShimAssembler(chanPointShim *lnrpc.ChanPointShim, initiator bool,
18901890
18911891// newFundingShimAssembler returns a new fully populated
18921892// chanfunding.PsbtAssembler using a FundingShim obtained from an RPC caller.
1893- func newPsbtAssembler (req * lnrpc.OpenChannelRequest , normalizedMinConfs int32 ,
1893+ func newPsbtAssembler (req * lnrpc.OpenChannelRequest ,
18941894 psbtShim * lnrpc.PsbtShim , netParams * chaincfg.Params ) (
18951895 chanfunding.Assembler , error ) {
18961896
@@ -1904,11 +1904,6 @@ func newPsbtAssembler(req *lnrpc.OpenChannelRequest, normalizedMinConfs int32,
19041904 if len (psbtShim .PendingChanId ) != 32 {
19051905 return nil , fmt .Errorf ("pending chan ID not set" )
19061906 }
1907- if normalizedMinConfs != 1 {
1908- return nil , fmt .Errorf ("setting non-default values for " +
1909- "minimum confirmation is not supported for PSBT " +
1910- "funding" )
1911- }
19121907 if req .SatPerByte != 0 || req .SatPerVbyte != 0 || req .TargetConf != 0 { // nolint:staticcheck
19131908 return nil , fmt .Errorf ("specifying fee estimation parameters " +
19141909 "is not supported for PSBT funding" )
@@ -2351,8 +2346,12 @@ func (r *rpcServer) OpenChannel(in *lnrpc.OpenChannelRequest,
23512346 // chanfunding.PsbtAssembler to construct the funding
23522347 // transaction.
23532348 copy (req .PendingChanID [:], psbtShim .PendingChanId )
2349+
2350+ // NOTE: For the PSBT case we do also allow unconfirmed
2351+ // utxos to fund the psbt transaction because we make
2352+ // sure we only use stable utxos.
23542353 req .ChanFunder , err = newPsbtAssembler (
2355- in , req . MinConfs , psbtShim ,
2354+ in , psbtShim ,
23562355 & r .server .cc .Wallet .Cfg .NetParams ,
23572356 )
23582357 if err != nil {
0 commit comments