mirror of
https://github.com/helm/helm.git
synced 2026-05-28 04:35:48 -04:00
fix(action): return correct error variable in prepareUpgrade
When Deployed() succeeds but releaserToV1Release() fails, prepareUpgrade returned err (nil) instead of cerr (the conversion error), causing a silent nil return that could lead to nil pointer dereferences downstream. Closes #32007 Signed-off-by: Rhys McNeill <rhysmcneill7@hotmail.co.uk>
This commit is contained in:
parent
1be395e7aa
commit
8ef2d45934
1 changed files with 1 additions and 1 deletions
|
|
@ -253,7 +253,7 @@ func (u *Upgrade) prepareUpgrade(name string, chart *chartv2.Chart, vals map[str
|
|||
var cerr error
|
||||
currentRelease, cerr = releaserToV1Release(currentReleasei)
|
||||
if cerr != nil {
|
||||
return nil, nil, false, err
|
||||
return nil, nil, false, cerr
|
||||
}
|
||||
if err != nil {
|
||||
if errors.Is(err, driver.ErrNoDeployedReleases) &&
|
||||
|
|
|
|||
Loading…
Reference in a new issue