summaryrefslogtreecommitdiffstats
path: root/api/user.go
diff options
context:
space:
mode:
authorCorey Hulen <corey@hulen.com>2017-08-16 09:51:45 -0700
committerChristopher Speller <crspeller@gmail.com>2017-08-16 09:51:45 -0700
commit0ab490845aed0ce3b58cbffd8ec35be237abda1c (patch)
tree5310cce7e546f5a03f97245af473b62d382028e8 /api/user.go
parent32265df8be5d530f5b79284792afb9451464ad3a (diff)
downloadchat-0ab490845aed0ce3b58cbffd8ec35be237abda1c.tar.gz
chat-0ab490845aed0ce3b58cbffd8ec35be237abda1c.tar.bz2
chat-0ab490845aed0ce3b58cbffd8ec35be237abda1c.zip
PLT-6226 Fixing races with licensing (#7213)
* PLT-6226 Fixing races with licensing * Fixing build issue * Fixing licensing issue * removing commented code
Diffstat (limited to 'api/user.go')
-rw-r--r--api/user.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/api/user.go b/api/user.go
index bb63cc7e2..8843a3730 100644
--- a/api/user.go
+++ b/api/user.go
@@ -302,7 +302,7 @@ func getInitialLoad(c *Context, w http.ResponseWriter, r *http.Request) {
il.ClientCfg = utils.ClientCfg
if app.SessionHasPermissionTo(c.Session, model.PERMISSION_MANAGE_SYSTEM) {
- il.LicenseCfg = utils.ClientLicense
+ il.LicenseCfg = utils.ClientLicense()
} else {
il.LicenseCfg = utils.GetSanitizedClientLicense()
}
@@ -1108,7 +1108,7 @@ func updateMfa(c *Context, w http.ResponseWriter, r *http.Request) {
}
func checkMfa(c *Context, w http.ResponseWriter, r *http.Request) {
- if !utils.IsLicensed || !*utils.License.Features.MFA || !*utils.Cfg.ServiceSettings.EnableMultifactorAuthentication {
+ if !utils.IsLicensed() || !*utils.License().Features.MFA || !*utils.Cfg.ServiceSettings.EnableMultifactorAuthentication {
rdata := map[string]string{}
rdata["mfa_required"] = "false"
w.Write([]byte(model.MapToJson(rdata)))