Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
adnxn committed Jan 12, 2018
1 parent 73fa556 commit 996e301
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions agent/eventhandler/task_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -184,14 +184,16 @@ func (handler *TaskHandler) taskStateChangesToSend() []api.TaskStateChange {
// safety mechanism) and add it to the list of task state changes
// that need to be sent to ECS
if task, ok := handler.state.TaskByArn(taskARN); ok {
event := api.TaskStateChange{
TaskARN: taskARN,
Status: task.GetKnownStatus(),
Task: task,
if task.GetKnownStatus() < api.TaskStopped {
event := api.TaskStateChange{
TaskARN: taskARN,
Status: task.GetKnownStatus(),
Task: task,
}
event.SetTaskTimestamps()

events = append(events, event)
}
event.SetTaskTimestamps()

events = append(events, event)
}
}
return events
Expand Down

0 comments on commit 996e301

Please sign in to comment.