@@ -127,7 +127,7 @@ func (c *Config) Dump() (string, error) {
127127 return string (d ), nil
128128}
129129
130- func (c * Config ) validate (isVenafi bool ) error {
130+ func (c * Config ) validate (isVenafiCloudMode bool ) error {
131131 var result * multierror.Error
132132
133133 // configured for Venafi Cloud
@@ -139,7 +139,7 @@ func (c *Config) validate(isVenafi bool) error {
139139 if _ , err := url .Parse (c .VenafiCloud .UploadPath ); err != nil {
140140 result = multierror .Append (result , fmt .Errorf ("upload_path is not a valid URL" ))
141141 }
142- } else if ! isVenafi {
142+ } else if ! isVenafiCloudMode {
143143 if c .OrganizationID == "" {
144144 result = multierror .Append (result , fmt .Errorf ("organization_id is required" ))
145145 }
@@ -167,7 +167,7 @@ func (c *Config) validate(isVenafi bool) error {
167167}
168168
169169// ParseConfig reads config into a struct used to configure running agents
170- func ParseConfig (data []byte , isVenafi bool ) (Config , error ) {
170+ func ParseConfig (data []byte , isVenafiCloudMode bool ) (Config , error ) {
171171 var config Config
172172
173173 err := yaml .Unmarshal (data , & config )
@@ -186,7 +186,7 @@ func ParseConfig(data []byte, isVenafi bool) (Config, error) {
186186 config .Endpoint .Protocol = "http"
187187 }
188188
189- err = config .validate (isVenafi )
189+ err = config .validate (isVenafiCloudMode )
190190 if err != nil {
191191 return config , err
192192 }
0 commit comments