Skip to content

Commit 9ee02a8

Browse files
rimoliveHumairAK
andauthored
Add a conditional to use the current condition timestamp if status does not change
Co-authored-by: Humair Khan <[email protected]>
1 parent a77290e commit 9ee02a8

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

controllers/dspipeline_controller.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -322,6 +322,8 @@ func (r *DSPAReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.
322322
for i, condition := range dspa.Status.Conditions {
323323
if condition.Status != conditions[i].Status {
324324
conditions[i].LastTransitionTime = metav1.Now()
325+
} else {
326+
conditions[i].LastTransitionTime = condition.LastTransitionTime
325327
}
326328
}
327329
dspa.Status.Conditions = conditions

0 commit comments

Comments
 (0)