From 4efcb075deb8756cc59f17c6e8a40f53092ee36e Mon Sep 17 00:00:00 2001 From: Elle Mouton Date: Mon, 30 Jun 2025 18:27:56 +0200 Subject: [PATCH] discovery: fix log line panic If a method returns an error, we should assume all other parameters to be nil unless the documentation explicitly says otherwise. So here, we fix a log line where a dereference is made to an object that will be nil due to an error being returned. --- discovery/gossiper.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/discovery/gossiper.go b/discovery/gossiper.go index 0b59c8af9..043ab1f61 100644 --- a/discovery/gossiper.go +++ b/discovery/gossiper.go @@ -2234,7 +2234,7 @@ func (d *AuthenticatedGossiper) isMsgStale(_ context.Context, } if err != nil { log.Debugf("Unable to retrieve channel=%v from graph: "+ - "%v", chanInfo.ChannelID, err) + "%v", msg.ShortChannelID, err) return false }