@@ -290,9 +290,9 @@ type ChannelLinkConfig struct {
290290 // restrict the flow of HTLCs and fee updates.
291291 MaxFeeExposure lnwire.MilliSatoshi
292292
293- // ShouldFwdExpEndorsement is a closure that indicates whether the link
294- // should forward experimental endorsement signals.
295- ShouldFwdExpEndorsement func () bool
293+ // ShouldFwdExpAccountability is a closure that indicates whether the
294+ // link should forward experimental accountability signals.
295+ ShouldFwdExpAccountability func () bool
296296
297297 // AuxTrafficShaper is an optional auxiliary traffic shaper that can be
298298 // used to manage the bandwidth of the link.
@@ -3163,11 +3163,11 @@ func (l *channelLink) processRemoteAdds(fwdPkg *channeldb.FwdPkg) {
31633163 continue
31643164 }
31653165
3166- endorseValue := l .experimentalEndorsement (
3166+ accountableValue := l .experimentalAccountability (
31673167 record .CustomSet (add .CustomRecords ),
31683168 )
3169- endorseType := uint64 (
3170- lnwire .ExperimentalEndorsementType ,
3169+ accountableType := uint64 (
3170+ lnwire .ExperimentalAccountableType ,
31713171 )
31723172
31733173 switch fwdPkg .State {
@@ -3191,9 +3191,9 @@ func (l *channelLink) processRemoteAdds(fwdPkg *channeldb.FwdPkg) {
31913191 BlindingPoint : fwdInfo .NextBlinding ,
31923192 }
31933193
3194- endorseValue .WhenSome (func (e byte ) {
3194+ accountableValue .WhenSome (func (e byte ) {
31953195 custRecords := map [uint64 ][]byte {
3196- endorseType : {e },
3196+ accountableType : {e },
31973197 }
31983198
31993199 outgoingAdd .CustomRecords = custRecords
@@ -3249,9 +3249,9 @@ func (l *channelLink) processRemoteAdds(fwdPkg *channeldb.FwdPkg) {
32493249 BlindingPoint : fwdInfo .NextBlinding ,
32503250 }
32513251
3252- endorseValue .WhenSome (func (e byte ) {
3252+ accountableValue .WhenSome (func (e byte ) {
32533253 addMsg .CustomRecords = map [uint64 ][]byte {
3254- endorseType : {e },
3254+ accountableType : {e },
32553255 }
32563256 })
32573257
@@ -3340,44 +3340,44 @@ func (l *channelLink) processRemoteAdds(fwdPkg *channeldb.FwdPkg) {
33403340 l .forwardBatch (reforward , switchPackets ... )
33413341}
33423342
3343- // experimentalEndorsement returns the value to set for our outgoing
3344- // experimental endorsement field, and a boolean indicating whether it should
3343+ // experimentalAccountability returns the value to set for our outgoing
3344+ // experimental accountable field, and a boolean indicating whether it should
33453345// be populated on the outgoing htlc.
3346- func (l * channelLink ) experimentalEndorsement (
3346+ func (l * channelLink ) experimentalAccountability (
33473347 customUpdateAdd record.CustomSet ) fn.Option [byte ] {
33483348
33493349 // Only relay experimental signal if we are within the experiment
33503350 // period.
3351- if ! l .cfg .ShouldFwdExpEndorsement () {
3351+ if ! l .cfg .ShouldFwdExpAccountability () {
33523352 return fn .None [byte ]()
33533353 }
33543354
33553355 // If we don't have any custom records or the experimental field is
33563356 // not set, just forward a zero value.
33573357 if len (customUpdateAdd ) == 0 {
3358- return fn.Some [byte ](lnwire .ExperimentalUnendorsed )
3358+ return fn.Some [byte ](lnwire .ExperimentalUnaccountable )
33593359 }
33603360
3361- t := uint64 (lnwire .ExperimentalEndorsementType )
3361+ t := uint64 (lnwire .ExperimentalAccountableType )
33623362 value , set := customUpdateAdd [t ]
33633363 if ! set {
3364- return fn.Some [byte ](lnwire .ExperimentalUnendorsed )
3364+ return fn.Some [byte ](lnwire .ExperimentalUnaccountable )
33653365 }
33663366
33673367 // We expect at least one byte for this field, consider it invalid if
33683368 // it has no data and just forward a zero value.
33693369 if len (value ) == 0 {
3370- return fn.Some [byte ](lnwire .ExperimentalUnendorsed )
3370+ return fn.Some [byte ](lnwire .ExperimentalUnaccountable )
33713371 }
33723372
3373- // Only forward endorsed if the incoming link is endorsed .
3374- if value [0 ] == lnwire .ExperimentalEndorsed {
3375- return fn.Some [byte ](lnwire .ExperimentalEndorsed )
3373+ // Only forward accountable if the incoming link is accountable .
3374+ if value [0 ] == lnwire .ExperimentalAccountable {
3375+ return fn.Some [byte ](lnwire .ExperimentalAccountable )
33763376 }
33773377
3378- // Forward as unendorsed otherwise, including cases where we've
3378+ // Forward as unaccountable otherwise, including cases where we've
33793379 // received an invalid value that uses more than 3 bits of information.
3380- return fn.Some [byte ](lnwire .ExperimentalUnendorsed )
3380+ return fn.Some [byte ](lnwire .ExperimentalUnaccountable )
33813381}
33823382
33833383// processExitHop handles an htlc for which this link is the exit hop. It
0 commit comments