mirror of
https://github.com/FairwindsOps/polaris.git
synced 2026-05-16 22:26:49 +00:00
skip resources that are empty strings (#131)
This commit is contained in:
@@ -99,6 +99,9 @@ func CreateResourceProviderFromPath(directory string) (*ResourceProvider, error)
|
||||
}
|
||||
specs := regexp.MustCompile("\n-+\n").Split(string(contents), -1)
|
||||
for _, spec := range specs {
|
||||
if strings.TrimSpace(spec) == "" {
|
||||
continue
|
||||
}
|
||||
err = addYaml(spec)
|
||||
if err != nil {
|
||||
logrus.Errorf("Error parsing YAML %v", err)
|
||||
|
||||
Reference in New Issue
Block a user