From fbff94f3be1bf596f2b94f593687d3b162413de9 Mon Sep 17 00:00:00 2001 From: Jesse Hallam Date: Mon, 5 Mar 2018 07:18:22 -0500 Subject: MM-8604: emit config/license websocket events (#8371) --- api4/system.go | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'api4/system.go') diff --git a/api4/system.go b/api4/system.go index aab65bf20..c1541f0b5 100644 --- a/api4/system.go +++ b/api4/system.go @@ -8,7 +8,6 @@ import ( "io" "net/http" "runtime" - "strconv" l4g "github.com/alecthomas/log4go" "github.com/mattermost/mattermost-server/model" @@ -247,14 +246,7 @@ func getClientConfig(c *Context, w http.ResponseWriter, r *http.Request) { return } - respCfg := map[string]string{} - for k, v := range c.App.ClientConfig() { - respCfg[k] = v - } - - respCfg["NoAccounts"] = strconv.FormatBool(c.App.IsFirstUserAccount()) - - w.Write([]byte(model.MapToJson(respCfg))) + w.Write([]byte(model.MapToJson(c.App.ClientConfigWithNoAccounts()))) } func getClientLicense(c *Context, w http.ResponseWriter, r *http.Request) { -- cgit v1.2.3-1-g7c22