mirror of https://github.com/status-im/consul.git
agent/http: fix service registration with nil checks value
This commit is contained in:
parent
b5e8111485
commit
8b0fe52be2
|
@ -142,7 +142,7 @@ func (s *HTTPServer) AgentRegisterService(resp http.ResponseWriter, req *http.Re
|
||||||
case "checks":
|
case "checks":
|
||||||
chkTypes, ok := v.([]interface{})
|
chkTypes, ok := v.([]interface{})
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil
|
continue
|
||||||
}
|
}
|
||||||
for _, chkType := range chkTypes {
|
for _, chkType := range chkTypes {
|
||||||
if err := FixupCheckType(chkType); err != nil {
|
if err := FixupCheckType(chkType); err != nil {
|
||||||
|
|
Loading…
Reference in New Issue