-
Notifications
You must be signed in to change notification settings - Fork 444
Closed
Labels
Description
In the JobRunner (and possibly other areas), the type hint currently limits you to working with closures. For more complex jobs, it is nicer to have an object because you can utilize DI and autoloading. Changing Closure
to callable
would maintain backwards compatibility and open up more options to the end user.
enqueue-dev/pkg/job-queue/JobRunner.php
Line 34 in 02f992c
public function runUnique($ownerId, $name, \Closure $runCallback) |
enqueue-dev/pkg/job-queue/JobRunner.php
Line 66 in 02f992c
public function createDelayed($name, \Closure $startCallback) |
enqueue-dev/pkg/job-queue/JobRunner.php
Line 81 in 02f992c
public function runDelayed($jobId, \Closure $runCallback) |