zpay32: rename to DefaultAssumedFinalCLTVDelta

This renames the paramter to clarify that this value is only used when
no CLTV value was decoded from the payment request
This commit is contained in:
Conner Fromknecht 2020-07-24 13:14:03 -07:00
parent 6622c4814e
commit 53ab22305d
No known key found for this signature in database
GPG Key ID: E7D737B67FA592C7
2 changed files with 5 additions and 4 deletions

View File

@ -3,9 +3,10 @@ package zpay32
import "github.com/btcsuite/btcd/btcec" import "github.com/btcsuite/btcd/btcec"
const ( const (
// DefaultFinalCLTVDelta is the default value to be used as the final // DefaultAssumedFinalCLTVDelta is the default value to be used as the
// CLTV delta for a route if one is unspecified. // final CLTV delta for a route if one is unspecified in the payment
DefaultFinalCLTVDelta = 9 // request.
DefaultAssumedFinalCLTVDelta = 9
) )
// HopHint is a routing hint that contains the minimum information of a channel // HopHint is a routing hint that contains the minimum information of a channel

View File

@ -324,7 +324,7 @@ func (invoice *Invoice) MinFinalCLTVExpiry() uint64 {
return *invoice.minFinalCLTVExpiry return *invoice.minFinalCLTVExpiry
} }
return DefaultFinalCLTVDelta return DefaultAssumedFinalCLTVDelta
} }
// validateInvoice does a sanity check of the provided Invoice, making sure it // validateInvoice does a sanity check of the provided Invoice, making sure it