@@ -1079,36 +1079,20 @@ func (b *BtcWallet) CreateSimpleTx(inputs fn.Set[wire.OutPoint],
10791079//
10801080// NOTE: This method requires the global coin selection lock to be held.
10811081func (b * BtcWallet ) LeaseOutput (id wtxmgr.LockID , op wire.OutPoint ,
1082- duration time.Duration ) (time.Time , [] byte , btcutil. Amount , error ) {
1082+ duration time.Duration ) (time.Time , error ) {
10831083
10841084 // Make sure we don't attempt to double lock an output that's been
10851085 // locked by the in-memory implementation.
10861086 if b .wallet .LockedOutpoint (op ) {
1087- return time.Time {}, nil , 0 , wtxmgr .ErrOutputAlreadyLocked
1087+ return time.Time {}, wtxmgr .ErrOutputAlreadyLocked
10881088 }
10891089
10901090 lockedUntil , err := b .wallet .LeaseOutput (id , op , duration )
10911091 if err != nil {
1092- return time.Time {}, nil , 0 , err
1092+ return time.Time {}, err
10931093 }
10941094
1095- // Get the pkScript and value for this lock from the list of all leased
1096- // outputs.
1097- allLeases , err := b .wallet .ListLeasedOutputs ()
1098- if err != nil {
1099- return time.Time {}, nil , 0 , err
1100- }
1101-
1102- for _ , lease := range allLeases {
1103- if lease .Outpoint == op {
1104- return lockedUntil , lease .PkScript ,
1105- btcutil .Amount (lease .Value ), nil
1106- }
1107- }
1108-
1109- // We MUST find the leased output in the loop above, otherwise something
1110- // is seriously wrong.
1111- return time.Time {}, nil , 0 , wtxmgr .ErrUnknownOutput
1095+ return lockedUntil , nil
11121096}
11131097
11141098// ListLeasedOutputs returns a list of all currently locked outputs.
0 commit comments