multi: use the "errors" package everywhere
Replace all usages of the "github.com/go-errors/errors" and "github.com/pkg/errors" packages with the standard lib's "errors" package. This ensures that error wrapping and `errors.Is` checks will work as expected.
This commit is contained in:
44 files changed
+114
-109
No files matched your search
@@ -1,6 +1,7 @@
|
||||
package graphdb
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"image/color"
|
||||
"net"
|
||||
@@ -11,7 +12,6 @@ import (
|
||||
"github.com/btcsuite/btcd/btcec/v2"
|
||||
"github.com/btcsuite/btcd/btcutil"
|
||||
"github.com/btcsuite/btcd/wire"
|
||||
"github.com/go-errors/errors"
|
||||
"github.com/lightningnetwork/lnd/fn/v2"
|
||||
"github.com/lightningnetwork/lnd/graph/db/models"
|
||||
"github.com/lightningnetwork/lnd/lnutils"
|
||||
@@ -412,8 +412,7 @@ func (c *ChannelGraph) addToTopologyChange(update *TopologyChange,
|
||||
// being connected.
|
||||
edgeInfo, _, _, err := c.FetchChannelEdgesByID(m.ChannelID)
|
||||
if err != nil {
|
||||
return errors.Errorf("unable fetch channel edge: %v",
|
||||
err)
|
||||
return fmt.Errorf("unable fetch channel edge: %w", err)
|
||||
}
|
||||
|
||||
// If the flag is one, then the advertising node is actually
|
||||
|
||||
Reference in new issue
Block a user