multi: add SpewLogClosure to avoid code repetition

This commit is contained in:
yyforyongyu committed 2024-07-25 22:18:49 +08:00
1 parent b6049ff94b
commit d992cf94d6
19 files changed
+57 -144

No files matched your search

+1 -4
View File
@@ -870,10 +870,7 @@ func (c *ChanCloser) ReceiveClosingSigned( //nolint:funlen
// With the closing transaction crafted, we'll now broadcast it
// to the network.
chancloserLog.Infof("Broadcasting cooperative close tx: %v",
lnutils.NewLogClosure(func() string {
return spew.Sdump(closeTx)
}),
)
lnutils.SpewLogClosure(closeTx))
// Create a close channel label.
chanID := c.cfg.Channel.ShortChanID()