From 6f639f922b05e8b26b5267a0ddd2a67f7cdc8b59 Mon Sep 17 00:00:00 2001 From: Vince Prignano Date: Mon, 9 Oct 2023 14:40:20 -0700 Subject: [PATCH] :bug: On deletion, should ignore if the secret cannot be found Signed-off-by: Vince Prignano --- controllers/awsmachine_controller.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controllers/awsmachine_controller.go b/controllers/awsmachine_controller.go index 252b10e741..dc8e47542b 100644 --- a/controllers/awsmachine_controller.go +++ b/controllers/awsmachine_controller.go @@ -777,7 +777,7 @@ func (r *AWSMachineReconciler) ignitionUserData(scope *scope.MachineScope, objec func (r *AWSMachineReconciler) deleteBootstrapData(machineScope *scope.MachineScope, clusterScope cloud.ClusterScoper, objectStoreScope scope.S3Scope) error { _, userDataFormat, err := machineScope.GetRawBootstrapDataWithFormat() - if err != nil { + if client.IgnoreNotFound(err) != nil { return errors.Wrap(err, "failed to get raw userdata") }