Skip to content

Commit

Permalink
Tolerate GetActiveCDI returning nil, nil (#2856)
Browse files Browse the repository at this point in the history
Seen in practice when deleting CDI CR in issue #2852

Signed-off-by: Maya Rashish <mrashish@redhat.com>
  • Loading branch information
maya-r committed Aug 22, 2023
1 parent b625320 commit b0f3da6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/operator/controller/cruft.go
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,7 @@ func (r *ReconcileCDI) watchCDICRD() error {
return nil
}
cr, err := cc.GetActiveCDI(context.TODO(), r.client)
if err != nil {
if err != nil || cr == nil {
return nil
}
return []reconcile.Request{
Expand Down

0 comments on commit b0f3da6

Please sign in to comment.