multi: add models.Node V1 constructor

Add a version field to models.Node and a V1 constructor for it.
This commit is contained in:
Elle Mouton authored and yyforyongyu committed 2025-11-12 22:54:05 +08:00
1 parent 8f205e2d1c
commit 80e70096cb
18 files changed
+443 -340

No files matched your search

+5 -3
View File
@@ -391,9 +391,11 @@ func (c *ChannelGraph) addToTopologyChange(update *TopologyChange,
nodeUpdate := &NetworkNodeUpdate{
Addresses: m.Addresses,
IdentityKey: pubKey,
Alias: m.Alias,
Color: EncodeHexColor(m.Color),
Features: m.Features.Clone(),
Alias: m.Alias.UnwrapOr(""),
Color: EncodeHexColor(
m.Color.UnwrapOr(color.RGBA{}),
),
Features: m.Features.Clone(),
}
update.NodeUpdates = append(update.NodeUpdates, nodeUpdate)