diff options
Diffstat (limited to 'api/license.go')
-rw-r--r-- | api/license.go | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/api/license.go b/api/license.go index b7bf8a234..cff7d7515 100644 --- a/api/license.go +++ b/api/license.go @@ -173,14 +173,17 @@ func RemoveLicense() *model.AppError { } func getClientLicenceConfig(c *Context, w http.ResponseWriter, r *http.Request) { - etag := utils.GetClientLicenseEtag(!c.IsSystemAdmin()) + useSanitizedLicense := !HasPermissionToContext(c, model.PERMISSION_MANAGE_SYSTEM) + c.Err = nil + + etag := utils.GetClientLicenseEtag(useSanitizedLicense) if HandleEtag(etag, w, r) { return } var clientLicense map[string]string - if c.IsSystemAdmin() { + if useSanitizedLicense { clientLicense = utils.ClientLicense } else { clientLicense = utils.GetSanitizedClientLicense() |