From 6bb7aa878dc6906c1e0af240f2e6d7d279bce259 Mon Sep 17 00:00:00 2001 From: Renato Monteiro <45536168+monteiro-renato@users.noreply.github.com> Date: Tue, 10 Dec 2024 15:40:46 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix:=20(helm/v1alpha1):=20remove?= =?UTF-8?q?=20redundant=20condition=20in=20if=20clause?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../templates/chart-templates/cert-manager/certificate.go | 2 +- .../dist/chart/templates/certmanager/certificate.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/cert-manager/certificate.go b/pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/cert-manager/certificate.go index 4d82986316d..7ea6b35c86e 100644 --- a/pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/cert-manager/certificate.go +++ b/pkg/plugins/optional/helm/v1alpha/scaffolds/internal/templates/chart-templates/cert-manager/certificate.go @@ -77,7 +77,7 @@ spec: name: selfsigned-issuer secretName: webhook-server-cert {{` + "`" + `{{- end }}` + "`" + `}} -{{ "{{- if and .Values.metrics.enable .Values.certmanager.enable }}" }} +{{ "{{- if .Values.metrics.enable }}" }} --- # Certificate for the metrics apiVersion: cert-manager.io/v1 diff --git a/testdata/project-v4-with-plugins/dist/chart/templates/certmanager/certificate.yaml b/testdata/project-v4-with-plugins/dist/chart/templates/certmanager/certificate.yaml index a4b67d26b06..64066ebc0cd 100644 --- a/testdata/project-v4-with-plugins/dist/chart/templates/certmanager/certificate.yaml +++ b/testdata/project-v4-with-plugins/dist/chart/templates/certmanager/certificate.yaml @@ -33,7 +33,7 @@ spec: name: selfsigned-issuer secretName: webhook-server-cert {{- end }} -{{- if and .Values.metrics.enable .Values.certmanager.enable }} +{{- if .Values.metrics.enable }} --- # Certificate for the metrics apiVersion: cert-manager.io/v1