zpay32: remove unused InvoiceFeatures
Originally the feature namespaces were destined to be split, but this has changed with the introduction of flat features.
This commit is contained in:
parent
3c6be62b18
commit
a77e111c52
@ -85,11 +85,8 @@ const (
|
||||
)
|
||||
|
||||
var (
|
||||
// InvoiceFeatures holds the set of all known feature bits that are
|
||||
// exposed as BOLT 11 features.
|
||||
InvoiceFeatures = map[lnwire.FeatureBit]string{}
|
||||
|
||||
// ErrInvoiceTooLarge is returned when an invoice exceeds maxInvoiceLength.
|
||||
// ErrInvoiceTooLarge is returned when an invoice exceeds
|
||||
// maxInvoiceLength.
|
||||
ErrInvoiceTooLarge = errors.New("invoice is too large")
|
||||
|
||||
// ErrInvalidFieldLength is returned when a tagged field was specified
|
||||
@ -934,7 +931,7 @@ func parseFeatures(data []byte) (*lnwire.FeatureVector, error) {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
fv := lnwire.NewFeatureVector(rawFeatures, InvoiceFeatures)
|
||||
fv := lnwire.NewFeatureVector(rawFeatures, lnwire.Features)
|
||||
unknownFeatures := fv.UnknownRequiredFeatures()
|
||||
if len(unknownFeatures) > 0 {
|
||||
return nil, fmt.Errorf("invoice contains unknown required "+
|
||||
|
@ -496,7 +496,7 @@ func TestDecodeEncode(t *testing.T) {
|
||||
Destination: testPubKey,
|
||||
Features: lnwire.NewFeatureVector(
|
||||
lnwire.NewRawFeatureVector(1, 9),
|
||||
InvoiceFeatures,
|
||||
lnwire.Features,
|
||||
),
|
||||
}
|
||||
},
|
||||
@ -523,7 +523,7 @@ func TestDecodeEncode(t *testing.T) {
|
||||
Destination: testPubKey,
|
||||
Features: lnwire.NewFeatureVector(
|
||||
lnwire.NewRawFeatureVector(1, 9, 100),
|
||||
InvoiceFeatures,
|
||||
lnwire.Features,
|
||||
),
|
||||
}
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user