discovery/gossiper: remove source pubkey from ProcessLocalAnnouncement params

This commit is contained in:
Johan T. Halseth committed 2021-02-11 15:13:51 +01:00
1 parent 69770f15e4
commit f047c3517f
3 files changed
+43 -110

No files matched your search

+2 -9
View File
@@ -1026,13 +1026,7 @@ func newServer(cfg *Config, listenAddrs []net.Addr,
CurrentNodeAnnouncement: func() (lnwire.NodeAnnouncement, error) {
return s.genNodeAnnouncement(true)
},
SendAnnouncement: func(msg lnwire.Message,
optionalFields ...discovery.OptionalMsgField) chan error {
return s.authGossiper.ProcessLocalAnnouncement(
msg, nodeKeyECDH.PubKey(), optionalFields...,
)
},
SendAnnouncement: s.authGossiper.ProcessLocalAnnouncement,
NotifyWhenOnline: s.NotifyWhenOnline,
TempChanIDSeed: chanIDSeed,
FindChannel: func(chanID lnwire.ChannelID) (
@@ -3792,8 +3786,7 @@ func (s *server) fetchLastChanUpdate() func(lnwire.ShortChannelID) (
// applyChannelUpdate applies the channel update to the different sub-systems of
// the server.
func (s *server) applyChannelUpdate(update *lnwire.ChannelUpdate) error {
pubKey := s.identityECDH.PubKey()
errChan := s.authGossiper.ProcessLocalAnnouncement(update, pubKey)
errChan := s.authGossiper.ProcessLocalAnnouncement(update)
select {
case err := <-errChan:
return err