mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-08 05:08:13 +02:00
multi: rename AnnounceSignatures to AnnounceSignatures1
In preparation for adding a new message, AnnounceSignatures2 along with an AnnounceSignatures interface, we rename the existing message to AnnounceSignatures1.
This commit is contained in:
@@ -481,8 +481,8 @@ type annBatch struct {
|
||||
chanUpdAnn1 *lnwire.ChannelUpdate
|
||||
chanUpdAnn2 *lnwire.ChannelUpdate
|
||||
|
||||
localProofAnn *lnwire.AnnounceSignatures
|
||||
remoteProofAnn *lnwire.AnnounceSignatures
|
||||
localProofAnn *lnwire.AnnounceSignatures1
|
||||
remoteProofAnn *lnwire.AnnounceSignatures1
|
||||
}
|
||||
|
||||
func createLocalAnnouncements(blockHeight uint32) (*annBatch, error) {
|
||||
@@ -513,7 +513,7 @@ func createAnnouncements(blockHeight uint32, key1, key2 *btcec.PrivateKey) (*ann
|
||||
return nil, err
|
||||
}
|
||||
|
||||
batch.remoteProofAnn = &lnwire.AnnounceSignatures{
|
||||
batch.remoteProofAnn = &lnwire.AnnounceSignatures1{
|
||||
ShortChannelID: lnwire.ShortChannelID{
|
||||
BlockHeight: blockHeight,
|
||||
},
|
||||
@@ -521,7 +521,7 @@ func createAnnouncements(blockHeight uint32, key1, key2 *btcec.PrivateKey) (*ann
|
||||
BitcoinSignature: batch.chanAnn.BitcoinSig2,
|
||||
}
|
||||
|
||||
batch.localProofAnn = &lnwire.AnnounceSignatures{
|
||||
batch.localProofAnn = &lnwire.AnnounceSignatures1{
|
||||
ShortChannelID: lnwire.ShortChannelID{
|
||||
BlockHeight: blockHeight,
|
||||
},
|
||||
@@ -1540,7 +1540,7 @@ out:
|
||||
case msg := <-sentToPeer:
|
||||
// Since the ChannelUpdate will also be resent as it is
|
||||
// sent reliably, we'll need to filter it out.
|
||||
if _, ok := msg.(*lnwire.AnnounceSignatures); !ok {
|
||||
if _, ok := msg.(*lnwire.AnnounceSignatures1); !ok {
|
||||
continue
|
||||
}
|
||||
|
||||
@@ -3302,7 +3302,7 @@ func TestSendChannelUpdateReliably(t *testing.T) {
|
||||
switch msg := msg.(type) {
|
||||
case *lnwire.ChannelUpdate:
|
||||
assertMessage(t, staleChannelUpdate, msg)
|
||||
case *lnwire.AnnounceSignatures:
|
||||
case *lnwire.AnnounceSignatures1:
|
||||
assertMessage(t, batch.localProofAnn, msg)
|
||||
default:
|
||||
t.Fatalf("send unexpected %v message", msg.MsgType())
|
||||
|
Reference in New Issue
Block a user