From 6a91263e38a5184fbe590869023cb61de028913a Mon Sep 17 00:00:00 2001 From: Taylor Thomas Date: Tue, 29 Oct 2019 11:13:03 -0600 Subject: [PATCH] fix(releaseutil): Removes API version checks from kind sorter The sorting method for manifests contained a check to see if the API version existed. This violates separation of concerns as the sorter should just sort and leave validation to other parts of the code. Signed-off-by: Taylor Thomas --- pkg/releaseutil/manifest_sorter.go | 4 ---- 1 file changed, 4 deletions(-) diff --git a/pkg/releaseutil/manifest_sorter.go b/pkg/releaseutil/manifest_sorter.go index 68ba1bf5e..5f4b4e8d9 100644 --- a/pkg/releaseutil/manifest_sorter.go +++ b/pkg/releaseutil/manifest_sorter.go @@ -129,10 +129,6 @@ func (file *manifestFile) sort(result *result) error { return errors.Wrapf(err, "YAML parse error on %s", file.path) } - if entry.Version != "" && !file.apis.Has(entry.Version) { - return errors.Errorf("apiVersion %q in %s is not available", entry.Version, file.path) - } - if !hasAnyAnnotation(entry) { result.generic = append(result.generic, Manifest{ Name: file.path,