Commit 8cf72adf authored by Taylor Thomas's avatar Taylor Thomas Committed by GitHub

Merge pull request #2711 from bonifaido/handle-tlspath-error

Redefine the err variable in NewChartRepository, otherwise errors migh slip through
parents 8eaed9d3 9f963c84
...@@ -60,7 +60,7 @@ func NewChartRepository(cfg *Entry, getters getter.Providers) (*ChartRepository, ...@@ -60,7 +60,7 @@ func NewChartRepository(cfg *Entry, getters getter.Providers) (*ChartRepository,
if err != nil { if err != nil {
return nil, fmt.Errorf("Could not find protocol handler for: %s", u.Scheme) return nil, fmt.Errorf("Could not find protocol handler for: %s", u.Scheme)
} }
client, _ := getterConstructor(cfg.URL, cfg.CertFile, cfg.KeyFile, cfg.CAFile) client, err := getterConstructor(cfg.URL, cfg.CertFile, cfg.KeyFile, cfg.CAFile)
if err != nil { if err != nil {
return nil, fmt.Errorf("Could not construct protocol handler for: %s", u.Scheme) return nil, fmt.Errorf("Could not construct protocol handler for: %s", u.Scheme)
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment