mirror of https://github.com/status-im/consul.git
Revert "local state: use synchronized access to internal maps"
This reverts commit 39a2d8d25e
.
This commit is contained in:
parent
4e862d126d
commit
d6f52d9ed1
|
@ -341,7 +341,7 @@ func (l *State) AddCheck(check *structs.HealthCheck, token string) error {
|
|||
|
||||
// if there is a serviceID associated with the check, make sure it exists before adding it
|
||||
// NOTE - This logic may be moved to be handled within the Agent's Addcheck method after a refactor
|
||||
if check.ServiceID != "" && l.Service(check.ServiceID) == nil {
|
||||
if check.ServiceID != "" && l.services[check.ServiceID] == nil {
|
||||
return fmt.Errorf("Check %q refers to non-existent service %q", check.CheckID, check.ServiceID)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue