diff --git a/agent/acl_endpoint.go b/agent/acl_endpoint.go index 2045063f8a..a61cdcd730 100644 --- a/agent/acl_endpoint.go +++ b/agent/acl_endpoint.go @@ -16,7 +16,7 @@ type aclCreateResponse struct { // ACLDisabled handles if ACL datacenter is not configured func ACLDisabled(resp http.ResponseWriter, req *http.Request) (interface{}, error) { - resp.WriteHeader(401) + resp.WriteHeader(http.StatusUnauthorized) // 401 fmt.Fprint(resp, "ACL support disabled") return nil, nil } diff --git a/agent/coordinate_endpoint.go b/agent/coordinate_endpoint.go index 922edbb84e..ee0ef06676 100644 --- a/agent/coordinate_endpoint.go +++ b/agent/coordinate_endpoint.go @@ -11,7 +11,7 @@ import ( // coordinateDisabled handles all the endpoints when coordinates are not enabled, // returning an error message. func coordinateDisabled(resp http.ResponseWriter, req *http.Request) (interface{}, error) { - resp.WriteHeader(401) + resp.WriteHeader(http.StatusUnauthorized) // 401 fmt.Fprint(resp, "Coordinate support disabled") return nil, nil }