replace errors.go with github.com/pkg/errors (1/2) (#3888)

* (1/2) of replace errors.go with github.com/pkg/errors

ref #3862

- step one in removing instances of errors.go in favor of github.com/pkg/errors

Signed-off-by: Marko Baricevic <marbar3778@yahoo.com>

* gofmt

* add in /store
This commit is contained in:
Marko
2019-08-08 14:31:13 +04:00
committed by Anton Kaliaev
parent d70135ec71
commit 8dc39b69b7
13 changed files with 53 additions and 47 deletions
+1 -1
View File
@@ -222,7 +222,7 @@ func (sw *Switch) OnStart() error {
for _, reactor := range sw.reactors {
err := reactor.Start()
if err != nil {
return cmn.ErrorWrap(err, "failed to start %v", reactor)
return errors.Wrapf(err, "failed to start %v", reactor)
}
}
+3 -1
View File
@@ -5,6 +5,8 @@ import (
"net"
"time"
"github.com/pkg/errors"
"github.com/tendermint/tendermint/crypto"
"github.com/tendermint/tendermint/crypto/ed25519"
cmn "github.com/tendermint/tendermint/libs/common"
@@ -233,7 +235,7 @@ func testPeerConn(
// Encrypt connection
conn, err = upgradeSecretConn(conn, cfg.HandshakeTimeout, ourNodePrivKey)
if err != nil {
return pc, cmn.ErrorWrap(err, "Error creating peer")
return pc, errors.Wrap(err, "Error creating peer")
}
// Only the information we already have