1
0
mirror of https://github.com/kidoman/embd synced 2024-12-22 04:40:04 +01:00

be specific about the unsupported host

This commit is contained in:
Karan Misra 2014-03-02 19:39:30 +05:30
parent 1ebbe540a5
commit 3cae4064dc

View File

@ -1,6 +1,6 @@
package host package host
import "errors" import "fmt"
type Descriptor struct { type Descriptor struct {
GPIO func() interface{} GPIO func() interface{}
@ -19,7 +19,7 @@ func Describe() (*Descriptor, error) {
describer, ok := Describers[host] describer, ok := Describers[host]
if !ok { if !ok {
return nil, errors.New("host: invalid host") return nil, fmt.Errorf("host: invalid host %q", host)
} }
return describer(rev), nil return describer(rev), nil