diff options
author | Harshil Sharma <harshil.sharma@joshtechnologygroup.com> | 2018-10-10 00:55:47 +0000 |
---|---|---|
committer | Jesse Hallam <jesse.hallam@gmail.com> | 2018-10-09 20:55:47 -0400 |
commit | bffcccf99de8a8f3c68cff9e39d2847f0996b67b (patch) | |
tree | 10bf45d87927dc792a233d0653d6ba273c9a7b28 /utils | |
parent | 59319b7915b8eb4c20a0d4878382cc0e41fc536d (diff) | |
download | chat-bffcccf99de8a8f3c68cff9e39d2847f0996b67b.tar.gz chat-bffcccf99de8a8f3c68cff9e39d2847f0996b67b.tar.bz2 chat-bffcccf99de8a8f3c68cff9e39d2847f0996b67b.zip |
Refactored to rename "service terms" to "terms of service" (#9581)
* #124 renamed identififers from service terms to terms of service
* #124 renamed identififers from service terms to terms of service
* 124 renamed ServiceTerms model to TermsOfService
* 124 Renamed EnableCustomServiceTerms feature flag to EnableCustomTermsOfService
* 124 Renamed EnableCustomServiceTerms feature flag to EnableCustomTermsOfService
* #124 fixed formatting
* #124 fixed formatting
* #132 renamed table ServiceTerms to TermsOfService
* #124 renamed some missed files from 'service_terms' to 'terms_of_service'
* #124 removed fixed TODOs
* drop migrate of ServiceTerms table, since backporting
* s/ServiceTerms/TermsOfService/ in tests
* s/AcceptedServiceTermsId/AcceptedTermsOfServiceId/
Change the model attribute, even though the column name will eventually be removed.
* s/accepted_service_terms_id/accepted_terms_of_service_id/ to match redux
* s/serviceTerms/termsOfService
* rename column too, and add max size constraint
* s/EnableCustomServiceTerms/EnableCustomTermsOfService
Diffstat (limited to 'utils')
-rw-r--r-- | utils/config.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/utils/config.go b/utils/config.go index 408598558..a779eef65 100644 --- a/utils/config.go +++ b/utils/config.go @@ -40,9 +40,9 @@ var ( "../../..", } - serviceTermsEnabledAndEmpty = model.NewAppError( + termsOfServiceEnabledAndEmpty = model.NewAppError( "Config.IsValid", - "model.config.is_valid.support.custom_service_terms_text.app_error", + "model.config.is_valid.support.custom_terms_of_service_text.app_error", nil, "", http.StatusBadRequest, @@ -482,10 +482,10 @@ func LoadConfig(fileName string) (*model.Config, string, map[string]interface{}, config.SetDefaults() - // Don't treat it as an error right now if custom service terms are enabled but text is empty. - // This is because service terms text will be fetched from database at a later state, but + // Don't treat it as an error right now if custom terms of service are enabled but text is empty. + // This is because terms of service text will be fetched from database at a later state, but // the flag indicating it is enabled is fetched from config file right away. - if err := config.IsValid(); err != nil && err.Id != serviceTermsEnabledAndEmpty.Id { + if err := config.IsValid(); err != nil && err.Id != termsOfServiceEnabledAndEmpty.Id { return nil, "", nil, err } @@ -703,7 +703,7 @@ func GenerateClientConfig(c *model.Config, diagnosticId string, license *model.L } if *license.Features.CustomTermsOfService { - props["EnableCustomServiceTerms"] = strconv.FormatBool(*c.SupportSettings.CustomServiceTermsEnabled) + props["EnableCustomTermsOfService"] = strconv.FormatBool(*c.SupportSettings.CustomTermsOfServiceEnabled) } } |