multi: move node ann validation code to netann pkg

The `netann` package is a more appropriate place for this code to live.
Also, once the funding transaction code is moved out of the
`graph.Builder`, then no `lnwire` validation will occur in the `graph`
package.
This commit is contained in:
Elle Mouton
2025-01-29 11:15:37 +02:00
parent 457a245a4e
commit 1974903fb2
3 changed files with 42 additions and 48 deletions

View File

@@ -1977,7 +1977,7 @@ func (d *AuthenticatedGossiper) fetchPKScript(chanID *lnwire.ShortChannelID) (
func (d *AuthenticatedGossiper) addNode(msg *lnwire.NodeAnnouncement,
op ...batch.SchedulerOption) error {
if err := graph.ValidateNodeAnn(msg); err != nil {
if err := netann.ValidateNodeAnn(msg); err != nil {
return fmt.Errorf("unable to validate node announcement: %w",
err)
}