Skip to content

Commit 0e722fb

Browse files
committed
Use a better name for looping variable
1 parent 17d150a commit 0e722fb

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

pkg/argocd/update.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -474,22 +474,22 @@ func marshalHelmOverride(app *v1alpha1.Application, originalData []byte) (overri
474474
return nil, unmarshalErr
475475
}
476476

477-
for _, c := range images {
478-
if c.ImageAlias == "" {
477+
for _, img := range images {
478+
if img.ImageAlias == "" {
479479
continue
480480
}
481481

482-
helmAnnotationParamName, helmAnnotationParamVersion := getHelmParamNamesFromAnnotation(app.Annotations, c)
482+
helmAnnotationParamName, helmAnnotationParamVersion := getHelmParamNamesFromAnnotation(app.Annotations, img)
483483

484484
if helmAnnotationParamName == "" {
485-
return nil, fmt.Errorf("could not find an image-name annotation for image %s", c.ImageName)
485+
return nil, fmt.Errorf("could not find an image-name annotation for image %s", img.ImageName)
486486
}
487487
// for image-spec annotation, helmAnnotationParamName holds image-spec annotation value,
488488
// and helmAnnotationParamVersion is empty
489489
if helmAnnotationParamVersion == "" {
490-
if c.GetParameterHelmImageSpec(app.Annotations, common.ImageUpdaterAnnotationPrefix) == "" {
490+
if img.GetParameterHelmImageSpec(app.Annotations, common.ImageUpdaterAnnotationPrefix) == "" {
491491
// not a full image-spec, so image-tag is required
492-
return nil, fmt.Errorf("could not find an image-tag annotation for image %s", c.ImageName)
492+
return nil, fmt.Errorf("could not find an image-tag annotation for image %s", img.ImageName)
493493
}
494494
} else {
495495
// image-tag annotation is present, so continue to process image-tag

0 commit comments

Comments
 (0)