Skip to content

Commit

Permalink
Fix logic error in one if/else.
Browse files Browse the repository at this point in the history
This fixes logic error where we had duplicated catch for the same
error - case where VeleroBackup was not found.

Signed-off-by: Michal Pryc <[email protected]>
  • Loading branch information
mpryc committed May 2, 2024
1 parent 94bbcd0 commit a40119a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/controller/nab_velero_backupspec.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func (r *NonAdminBackupReconciler) CreateVeleroBackupSpec(ctx context.Context, l
},
Spec: *backupSpec,
}
} else if err != nil && !apierrors.IsNotFound(err) {
} else if err != nil {
logger.Error(err, "Unable to fetch VeleroBackup")
return true, false, err
} else {
Expand Down

0 comments on commit a40119a

Please sign in to comment.