Skip to content

Commit

Permalink
refactor error
Browse files Browse the repository at this point in the history
  • Loading branch information
Kifen committed Mar 6, 2020
1 parent f09b147 commit 22056bf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions pkg/app/appnet/skywire_networker.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package appnet
import (
"context"
"errors"
"fmt"
"io"
"net"
"strings"
Expand Down Expand Up @@ -53,7 +52,7 @@ func (r *SkywireNetworker) DialContext(ctx context.Context, addr Addr) (net.Conn

rPK := addr.PubKey
if rPK.Null() {
return nil, fmt.Errorf("Empty public key: %s", rPK)
return nil, errors.New("cannot dial to address with empty public key")
}

rg, err := r.r.DialRoutes(ctx, rPK, routing.Port(localPort), addr.Port, router.DefaultDialOptions())
Expand Down
2 changes: 1 addition & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# github.com/SkycoinProject/dmsg v0.0.0-20200306131535-fabb2c8177e9 => ../dmsg
# github.com/SkycoinProject/dmsg v0.0.0-20200306152741-acee74fa4514
github.com/SkycoinProject/dmsg
github.com/SkycoinProject/dmsg/cipher
github.com/SkycoinProject/dmsg/disc
Expand Down

0 comments on commit 22056bf

Please sign in to comment.