feat(httpd): Return 403 Forbidden when Flux API is disabled
parent
ff416805c5
commit
f6426f269d
|
@ -209,7 +209,7 @@ func NewHandler(c Config) *Handler {
|
|||
|
||||
if !c.FluxEnabled {
|
||||
fluxRoute.HandlerFunc = func(w http.ResponseWriter, r *http.Request) {
|
||||
http.Error(w, "Flux query service disabled. Verify flux-enabled=true in the [http] section of the InfluxDB config.", http.StatusNotFound)
|
||||
http.Error(w, "Flux query service disabled. Verify flux-enabled=true in the [http] section of the InfluxDB config.", http.StatusForbidden)
|
||||
}
|
||||
} else {
|
||||
fluxRoute.HandlerFunc = h.serveFluxQuery
|
||||
|
|
Loading…
Reference in New Issue