diff --git a/schedule.go b/schedule.go index 09e2f0e..085e39e 100644 --- a/schedule.go +++ b/schedule.go @@ -236,7 +236,7 @@ func (s *ScheduleImpl) On(ctx context.Context, kind string, handler func(ctx con return err } - go handler(ctx, &Task{ + handler(ctx, &Task{ ID: id, Kind: kind, Interval: time.Duration(taskData.Interval) * time.Millisecond,