mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-13 18:10:25 +02:00
autopilot/prefattach: skip nodes having no channels
This commit is contained in:
@@ -166,6 +166,11 @@ func (p *ConstrainedPrefAttachment) NodeScores(g ChannelGraph, chans []Channel,
|
|||||||
// skip it for now, which implicitly gives it a score of 0.
|
// skip it for now, which implicitly gives it a score of 0.
|
||||||
case len(addrs) == 0:
|
case len(addrs) == 0:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
// If the node had no channels, we skip it, since it would have
|
||||||
|
// gotten a zero score anyway.
|
||||||
|
case nodeChans == 0:
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
// Otherwise we score the node according to its fraction of
|
// Otherwise we score the node according to its fraction of
|
||||||
|
Reference in New Issue
Block a user