From 500e8d7e164cb2d8c307b4bc4a6a5faf4a72d249 Mon Sep 17 00:00:00 2001 From: Maxim Goncharenko Date: Mon, 20 May 2019 18:28:54 +0300 Subject: [PATCH] Fixed string and float type mismatches --- pkg/engine/validation.go | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/pkg/engine/validation.go b/pkg/engine/validation.go index 77521deee7..a6b55cadaf 100644 --- a/pkg/engine/validation.go +++ b/pkg/engine/validation.go @@ -144,13 +144,7 @@ func validateMapElement(resourcePart, patternPart interface{}) error { return validateArray(array, pattern) case string: - str, ok := resourcePart.(string) - - if !ok { - return fmt.Errorf("expected %T, found %T", patternPart, resourcePart) - } - - return checkSingleValue(str, pattern) + return checkSingleValue(resourcePart, patternPart) case float64: switch num := resourcePart.(type) { case float64: