From 7ce0c8d68a7d006454f80e88b362a3e05b7192b4 Mon Sep 17 00:00:00 2001 From: shravan Date: Thu, 2 Apr 2020 21:19:51 +0530 Subject: [PATCH] 787 circle ci changes --- pkg/kyverno/apply/command.go | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/pkg/kyverno/apply/command.go b/pkg/kyverno/apply/command.go index a99cff4646..75ee885986 100644 --- a/pkg/kyverno/apply/command.go +++ b/pkg/kyverno/apply/command.go @@ -395,8 +395,5 @@ func applyPolicyOnResource(policy *v1.ClusterPolicy, resource *unstructured.Unst func policyHasVariables(policy v1.ClusterPolicy) bool { policyRaw, _ := json.Marshal(policy) regex := regexp.MustCompile(`\{\{([^{}]*)\}\}`) - if len(regex.FindAllStringSubmatch(string(policyRaw), -1)) > 0 { - return true - } - return false + return len(regex.FindAllStringSubmatch(string(policyRaw), -1)) > 0 }