Skip to content

Commit

Permalink
Merge pull request #624 from cheese-head/main
Browse files Browse the repository at this point in the history
🐛 Fix patchErr not being checked in packetmachine_controller
  • Loading branch information
k8s-ci-robot authored Aug 14, 2023
2 parents e9c2ee0 + c81521e commit 3cd1612
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion controllers/packetmachine_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ func (r *PacketMachineReconciler) reconcile(ctx context.Context, machineScope *s
// Avoid a flickering condition between InstanceProvisionStarted and InstanceProvisionFailed if there's a persistent failure with createInstance
if conditions.GetReason(machineScope.PacketMachine, infrav1.DeviceReadyCondition) != infrav1.InstanceProvisionFailedReason {
conditions.MarkFalse(machineScope.PacketMachine, infrav1.DeviceReadyCondition, infrav1.InstanceProvisionStartedReason, clusterv1.ConditionSeverityInfo, "")
if patchErr := machineScope.PatchObject(ctx); err != nil {
if patchErr := machineScope.PatchObject(ctx); patchErr != nil {
log.Error(patchErr, "failed to patch conditions")
return ctrl.Result{}, patchErr
}
Expand Down

0 comments on commit 3cd1612

Please sign in to comment.