From 2ee213766eaf755b99d23a261c8d36b54b5d7ff3 Mon Sep 17 00:00:00 2001 From: Ahmed Mezghani Date: Mon, 4 Apr 2022 10:38:35 +0200 Subject: [PATCH] Log the configured config without ToLower --- pkg/clusteragent/admission/controllers/webhook/controller_v1.go | 2 +- .../admission/controllers/webhook/controller_v1beta1.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/clusteragent/admission/controllers/webhook/controller_v1.go b/pkg/clusteragent/admission/controllers/webhook/controller_v1.go index 7dfecb1a041931..e0c9559996238e 100644 --- a/pkg/clusteragent/admission/controllers/webhook/controller_v1.go +++ b/pkg/clusteragent/admission/controllers/webhook/controller_v1.go @@ -267,7 +267,7 @@ func (c *ControllerV1) getReinvocationPolicy() admiv1.ReinvocationPolicyType { case "never": return admiv1.NeverReinvocationPolicy default: - log.Warnf("Unknown reinvocation policy %q - defaulting to %q", policy, admiv1.IfNeededReinvocationPolicy) + log.Warnf("Unknown reinvocation policy %q - defaulting to %q", c.config.getReinvocationPolicy(), admiv1.IfNeededReinvocationPolicy) return admiv1.IfNeededReinvocationPolicy } } diff --git a/pkg/clusteragent/admission/controllers/webhook/controller_v1beta1.go b/pkg/clusteragent/admission/controllers/webhook/controller_v1beta1.go index 2f40d507985aae..17233253a8a464 100644 --- a/pkg/clusteragent/admission/controllers/webhook/controller_v1beta1.go +++ b/pkg/clusteragent/admission/controllers/webhook/controller_v1beta1.go @@ -267,7 +267,7 @@ func (c *ControllerV1beta1) getReinvocationPolicy() admiv1beta1.ReinvocationPoli case "never": return admiv1beta1.NeverReinvocationPolicy default: - log.Warnf("Unknown reinvocation policy %q - defaulting to %q", policy, admiv1beta1.IfNeededReinvocationPolicy) + log.Warnf("Unknown reinvocation policy %q - defaulting to %q", c.config.getReinvocationPolicy(), admiv1beta1.IfNeededReinvocationPolicy) return admiv1beta1.IfNeededReinvocationPolicy } }