Skip to content

Commit d151abe

Browse files
committed
chore(queue): missing timeout.
Signed-off-by: Bo-Yi Wu <[email protected]>
1 parent f4074cb commit d151abe

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

queue.go

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -167,9 +167,13 @@ func (q *Queue) handleQueueTask(timeout time.Duration, task TaskFunc) error {
167167
return ErrQueueShutdown
168168
}
169169

170-
return q.worker.Queue(Job{
171-
Task: task,
170+
data := Job{
172171
Timeout: timeout,
172+
}
173+
174+
return q.worker.Queue(Job{
175+
Task: task,
176+
Body: data.Encode(),
173177
})
174178
}
175179

0 commit comments

Comments
 (0)