This commit is contained in:
Yann Hamon 2020-06-01 05:08:45 +02:00
parent a33ba035fa
commit 742d8cdf7e
2 changed files with 5 additions and 1 deletions

View file

@ -81,6 +81,10 @@ func validateFile(r io.Reader, regs []registry.Registry, k8sVersion string, c *c
continue
}
if sig.Kind == "" {
continue // We skip resoures that don't have a Kind defined
}
if skip(sig) {
validationResults = append(validationResults, validationResult{kind: sig.Kind, version: sig.Version, err: nil, skipped: true})
continue

View file

@ -18,7 +18,7 @@ func FindYamlInDir(dir string, fileBatches chan<- []string, batchSize int) error
files = append(files, path)
if len(files) > batchSize {
fileBatches <- files
files = nil
files = []string{}
}
}
return nil