features: define temporary AMP feature bits 30/31

This commit is contained in:
Conner Fromknecht
2021-03-24 19:48:08 -07:00
parent c2729cbbbd
commit 438b03afa4
4 changed files with 22 additions and 0 deletions

View File

@@ -51,4 +51,9 @@ var defaultSetDesc = setDesc{
SetInit: {}, // I
SetNodeAnn: {}, // N
},
lnwire.AMPOptional: {
SetInit: {}, // I
SetNodeAnn: {}, // N
SetInvoice: {}, // 9
},
}

View File

@@ -58,6 +58,9 @@ var deps = depDesc{
lnwire.AnchorsOptional: {
lnwire.StaticRemoteKeyOptional: {},
},
lnwire.AMPOptional: {
lnwire.PaymentAddrOptional: {},
},
}
// ValidateDeps asserts that a feature vector sets all features and their

View File

@@ -77,6 +77,8 @@ func newManager(cfg Config, desc setDesc) (*Manager, error) {
raw.Unset(lnwire.PaymentAddrRequired)
raw.Unset(lnwire.MPPOptional)
raw.Unset(lnwire.MPPRequired)
raw.Unset(lnwire.AMPOptional)
raw.Unset(lnwire.AMPRequired)
}
if cfg.NoStaticRemoteKey {
raw.Unset(lnwire.StaticRemoteKeyOptional)