From 9a7f66f2f73f97bceb74b5b23246bf4f6c6667fa Mon Sep 17 00:00:00 2001 From: Wilmer Paulino Date: Fri, 13 Dec 2019 16:09:16 -0800 Subject: [PATCH] peer: modify ReplyChannelRange log message The message now shows the block range the reply spans, which is a lot more useful. --- peer.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/peer.go b/peer.go index 53092edb..7a901413 100644 --- a/peer.go +++ b/peer.go @@ -1336,8 +1336,10 @@ func messageSummary(msg lnwire.Message) string { msg.Complete) case *lnwire.ReplyChannelRange: - return fmt.Sprintf("complete=%v, encoding=%v, num_chans=%v", - msg.Complete, msg.EncodingType, len(msg.ShortChanIDs)) + return fmt.Sprintf("start_height=%v, end_height=%v, "+ + "num_chans=%v, encoding=%v", msg.FirstBlockHeight, + msg.LastBlockHeight(), len(msg.ShortChanIDs), + msg.EncodingType) case *lnwire.QueryShortChanIDs: return fmt.Sprintf("chain_hash=%v, encoding=%v, num_chans=%v", @@ -1345,8 +1347,8 @@ func messageSummary(msg lnwire.Message) string { case *lnwire.QueryChannelRange: return fmt.Sprintf("chain_hash=%v, start_height=%v, "+ - "num_blocks=%v", msg.ChainHash, msg.FirstBlockHeight, - msg.NumBlocks) + "end_height=%v", msg.ChainHash, msg.FirstBlockHeight, + msg.LastBlockHeight()) case *lnwire.GossipTimestampRange: return fmt.Sprintf("chain_hash=%v, first_stamp=%v, "+