1
0
mirror of https://github.com/ipfs/kubo.git synced 2025-07-01 10:49:24 +08:00

refactor(namesys) use one-off error

This commit is contained in:
Brian Tiger Chow
2014-10-28 02:22:32 -07:00
parent 04e270a91e
commit c534daef86

View File

@ -1,13 +1,12 @@
package namesys package namesys
import ( import (
"fmt"
"net" "net"
b58 "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-base58" b58 "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-base58"
isd "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-is-domain" isd "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-is-domain"
mh "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multihash" mh "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multihash"
u "github.com/jbenet/go-ipfs/util"
) )
// DNSResolver implements a Resolver on DNS domains // DNSResolver implements a Resolver on DNS domains
@ -44,5 +43,5 @@ func (r *DNSResolver) Resolve(name string) (string, error) {
return t, nil return t, nil
} }
return "", u.ErrNotFound return "", fmt.Errorf("namesys: %v not found", name)
} }