diff --git a/pkg/app/app.go b/pkg/app/app.go index 5fd913a3..fd75a71b 100644 --- a/pkg/app/app.go +++ b/pkg/app/app.go @@ -982,10 +982,8 @@ func (a *App) visitStatesWithSelectorsAndRemoteSupport(fileOrDir string, converg envvals := []interface{}{} - if a.ValuesFiles != nil { - for i := range a.ValuesFiles { - envvals = append(envvals, a.ValuesFiles[i]) - } + for _, v := range a.ValuesFiles { + envvals = append(envvals, v) } if a.Set != nil { diff --git a/pkg/state/create.go b/pkg/state/create.go index 816774d3..1975ed05 100644 --- a/pkg/state/create.go +++ b/pkg/state/create.go @@ -90,11 +90,9 @@ func (c *StateCreator) Parse(content []byte, baseDir, file string) (*HelmState, state.basePath = baseDir decoder := yaml.NewDecoder(bytes.NewReader(content)) - if !c.Strict { - decoder.SetStrict(false) - } else { - decoder.SetStrict(true) - } + + decoder.SetStrict(c.Strict) + i := 0 for { i++