From f97417a8a49462c6d5a4365ff584894bf84f4560 Mon Sep 17 00:00:00 2001 From: Guilherme Cassolato Date: Fri, 1 Dec 2023 17:12:51 +0100 Subject: [PATCH] Fix Istio AuthorizationPolicy mutate check (#351) --- controllers/authpolicy_istio_authorizationpolicy.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controllers/authpolicy_istio_authorizationpolicy.go b/controllers/authpolicy_istio_authorizationpolicy.go index b4fdfe92c..3453d21e5 100644 --- a/controllers/authpolicy_istio_authorizationpolicy.go +++ b/controllers/authpolicy_istio_authorizationpolicy.go @@ -373,7 +373,7 @@ func alwaysUpdateAuthPolicy(existingObj, desiredObj client.Object) (bool, error) existing.Spec.Selector = desired.Spec.Selector } - if reflect.DeepEqual(existing.Annotations, desired.Annotations) { + if !reflect.DeepEqual(existing.Annotations, desired.Annotations) { update = true existing.Annotations = desired.Annotations }