From e58abbf0e540f284a0057654efe27947f9e9ae82 Mon Sep 17 00:00:00 2001 From: Elle Mouton Date: Tue, 18 Feb 2025 11:04:27 -0300 Subject: [PATCH] graph/db: fix edges bucket check This commit fixes a bug that would check that the passed `edge` argument of UpdateChannelEdge is nil but it should actually be checking if the `edges` bucket is nil. --- graph/db/graph.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/graph/db/graph.go b/graph/db/graph.go index 8004a2a5d..11943c7e9 100644 --- a/graph/db/graph.go +++ b/graph/db/graph.go @@ -1309,7 +1309,7 @@ func (c *ChannelGraph) UpdateChannelEdge(edge *models.ChannelEdgeInfo) error { return kvdb.Update(c.db, func(tx kvdb.RwTx) error { edges := tx.ReadWriteBucket(edgeBucket) - if edge == nil { + if edges == nil { return ErrEdgeNotFound }