fix golint issues in core/discov (#479)
This commit is contained in:
@@ -2,11 +2,13 @@ package discov
|
||||
|
||||
import "errors"
|
||||
|
||||
// EtcdConf is the config item with the given key on etcd.
|
||||
type EtcdConf struct {
|
||||
Hosts []string
|
||||
Key string
|
||||
}
|
||||
|
||||
// Validate validates c.
|
||||
func (c EtcdConf) Validate() error {
|
||||
if len(c.Hosts) == 0 {
|
||||
return errors.New("empty etcd hosts")
|
||||
|
||||
Reference in New Issue
Block a user