diff --git a/manager/orchestrator/global/global.go b/manager/orchestrator/global/global.go index 28c2a436d3..c08f0eb46d 100644 --- a/manager/orchestrator/global/global.go +++ b/manager/orchestrator/global/global.go @@ -504,7 +504,7 @@ func (g *Orchestrator) removeTasks(ctx context.Context, batch *store.Batch, task } func isTaskRunning(t *api.Task) bool { - return t != nil && t.DesiredState <= api.TaskStateRunning && t.Status.State <= api.TaskStateRunning + return t != nil && t.DesiredState <= api.TaskStateRunning } func isTaskCompleted(t *api.Task, restartPolicy api.RestartPolicy_RestartCondition) bool {