diff --git a/models/workflow_execution/workflow_scheduler.go b/models/workflow_execution/workflow_scheduler.go index 91888e3..b1c6b38 100644 --- a/models/workflow_execution/workflow_scheduler.go +++ b/models/workflow_execution/workflow_scheduler.go @@ -91,8 +91,8 @@ func (ws *WorkflowSchedule) CheckBooking(wfID string, request *tools.APIRequest) go getBooking(l, b, request, wf, execs, bookings, errCh) } - for err := range(errCh){ - if err != nil { + for i := 0; i < len(bookings); i++ { + if err := <-errCh; err != nil { return false, wf, execs, bookings, err } }