lnrpc/peers: handle alias changes in updateNodeAnnouncement

This commit is contained in:
positiveblue committed 2022-04-01 18:36:26 -07:00
1 parent e4e0935816
commit ce4813940d
4 files changed
+165 -6

No files matched your search

+8
View File
@@ -13,6 +13,14 @@ import (
// lnwire.NodeAnnouncement.
type NodeAnnModifier func(*lnwire.NodeAnnouncement)
// NodeAnnSetAlias is a functional option that sets the alias of the
// given node announcment.
func NodeAnnSetAlias(alias lnwire.NodeAlias) func(*lnwire.NodeAnnouncement) {
return func(nodeAnn *lnwire.NodeAnnouncement) {
nodeAnn.Alias = alias
}
}
// NodeAnnSetAddrs is a functional option that allows updating the addresses of
// the given node announcement.
func NodeAnnSetAddrs(addrs []net.Addr) func(*lnwire.NodeAnnouncement) {