mirror of
https://github.com/coder/coder.git
synced 2025-07-15 22:20:27 +00:00
chore: reword license backend error to only mention premium (#14799)
Phrasing for "enterprise" removed.
This commit is contained in:
@ -354,12 +354,9 @@ func (api *API) RequireFeatureMW(feat codersdk.FeatureName) func(http.Handler) h
|
||||
return http.HandlerFunc(func(rw http.ResponseWriter, r *http.Request) {
|
||||
// Entitlement must be enabled.
|
||||
if !api.Entitlements.Enabled(feat) {
|
||||
licenseType := "a Premium"
|
||||
if feat.Enterprise() {
|
||||
licenseType = "an Enterprise"
|
||||
}
|
||||
// All feature warnings should be "Premium", not "Enterprise".
|
||||
httpapi.Write(r.Context(), rw, http.StatusForbidden, codersdk.Response{
|
||||
Message: fmt.Sprintf("%s is %s feature. Contact sales!", feat.Humanize(), licenseType),
|
||||
Message: fmt.Sprintf("%s is a Premium feature. Contact sales!", feat.Humanize()),
|
||||
})
|
||||
return
|
||||
}
|
||||
|
Reference in New Issue
Block a user