We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6ed706c commit b26dc35Copy full SHA for b26dc35
Models/Worker.js
@@ -34,6 +34,10 @@ export default class Worker {
34
*/
35
addWorker(jobName, worker, options = {}) {
36
37
+ if (!jobName || !worker) {
38
+ throw new Error('Job name and associated function must be supplied.');
39
+ }
40
+
41
// Attach options to worker
42
worker.options = {
43
concurrency: options.concurrency || 1
0 commit comments