Settings: Remove global variable (#26613)

This commit is contained in:
Torkel Ödegaard
2020-07-26 23:36:36 -07:00
committed by GitHub
parent ae3c285312
commit 3defb4441e
2 changed files with 1 additions and 12 deletions
+1 -2
View File
@@ -7,7 +7,6 @@ import (
"github.com/grafana/grafana/pkg/models"
"github.com/grafana/grafana/pkg/plugins"
"github.com/grafana/grafana/pkg/setting"
"github.com/grafana/grafana/pkg/api/dtos"
"github.com/grafana/grafana/pkg/bus"
@@ -77,7 +76,7 @@ func (hs *HTTPServer) QueryMetricsV2(c *models.ReqContext, reqDto dtos.MetricReq
return Error(500, "Metric request error", err)
}
} else {
if !setting.IsExpressionsEnabled() {
if !hs.Cfg.IsExpressionsEnabled() {
return Error(404, "Expressions feature toggle is not enabled", nil)
}