summaryrefslogtreecommitdiffstats
path: root/api
diff options
context:
space:
mode:
Diffstat (limited to 'api')
-rw-r--r--api/context.go2
-rw-r--r--api/general.go3
-rw-r--r--api/user.go2
3 files changed, 3 insertions, 4 deletions
diff --git a/api/context.go b/api/context.go
index 2842e63a7..4f47271e2 100644
--- a/api/context.go
+++ b/api/context.go
@@ -151,7 +151,7 @@ func (h handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
c.SetSiteURLHeader(app.GetProtocol(r) + "://" + r.Host)
w.Header().Set(model.HEADER_REQUEST_ID, c.RequestId)
- w.Header().Set(model.HEADER_VERSION_ID, fmt.Sprintf("%v.%v.%v.%v", model.CurrentVersion, model.BuildNumber, utils.ClientCfgHash, utils.IsLicensed()))
+ w.Header().Set(model.HEADER_VERSION_ID, fmt.Sprintf("%v.%v.%v.%v", model.CurrentVersion, model.BuildNumber, c.App.ClientConfigHash(), utils.IsLicensed()))
// Instruct the browser not to display us in an iframe unless is the same origin for anti-clickjacking
if !h.isApi {
diff --git a/api/general.go b/api/general.go
index 0fd289ffb..94da47330 100644
--- a/api/general.go
+++ b/api/general.go
@@ -9,7 +9,6 @@ import (
"strings"
"github.com/mattermost/mattermost-server/model"
- "github.com/mattermost/mattermost-server/utils"
)
func (api *API) InitGeneral() {
@@ -19,7 +18,7 @@ func (api *API) InitGeneral() {
}
func getClientConfig(c *Context, w http.ResponseWriter, r *http.Request) {
- w.Write([]byte(model.MapToJson(utils.ClientCfg)))
+ w.Write([]byte(model.MapToJson(c.App.ClientConfig())))
}
func logClient(c *Context, w http.ResponseWriter, r *http.Request) {
diff --git a/api/user.go b/api/user.go
index f9b0af469..55042498a 100644
--- a/api/user.go
+++ b/api/user.go
@@ -297,7 +297,7 @@ func getInitialLoad(c *Context, w http.ResponseWriter, r *http.Request) {
il.NoAccounts = c.App.IsFirstUserAccount()
}
- il.ClientCfg = utils.ClientCfg
+ il.ClientCfg = c.App.ClientConfig()
if c.App.SessionHasPermissionTo(c.Session, model.PERMISSION_MANAGE_SYSTEM) {
il.LicenseCfg = utils.ClientLicense()
} else {