Skip to content

Commit 96a17ef

Browse files
authored
Merge pull request #672 from fluxcd/fix-drift-nil-deref
Fix nil pointer deref during diff attempt
2 parents 8448b1d + 32b5d7e commit 96a17ef

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/controllers/helmrelease_controller.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ func (r *HelmReleaseReconciler) reconcileRelease(ctx context.Context,
329329
hr, hasNewState := v2.HelmReleaseAttempted(hr, revision, releaseRevision, valuesChecksum)
330330

331331
// Run diff against current cluster state.
332-
if !hasNewState {
332+
if !hasNewState && rel != nil {
333333
if ok, _ := features.Enabled(features.DetectDrift); ok {
334334
differ := diff.NewDiffer(runtimeClient.NewImpersonator(
335335
r.Client,

0 commit comments

Comments
 (0)