1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2025-03-29 10:55:05 +00:00
This commit is contained in:
shivkumar dudhani 2020-03-20 09:18:15 -07:00
parent 36eca5e886
commit 6e822ece40

View file

@ -6,9 +6,5 @@ import "regexp"
func IsVariable(element string) bool {
validRegex := regexp.MustCompile(variableRegex)
groups := validRegex.FindAllStringSubmatch(element, -1)
if len(groups) == 0 {
// there was no match
return false
}
return true
return len(groups) != 0
}