diff --git a/src/classes/job-scheduler.ts b/src/classes/job-scheduler.ts index 8bba169f92..63c0f8199c 100644 --- a/src/classes/job-scheduler.ts +++ b/src/classes/job-scheduler.ts @@ -194,7 +194,7 @@ export class JobScheduler extends QueueBase { mergedOpts.repeat = { ...opts.repeat, count: currentCount }; - const job = new Job(this, name, data, mergedOpts, jobId); + const job = new this.Job(this, name, data, mergedOpts, jobId); job.addJob(client); return job; diff --git a/src/classes/queue-getters.ts b/src/classes/queue-getters.ts index 8740cf5df4..29e0e9d1c3 100644 --- a/src/classes/queue-getters.ts +++ b/src/classes/queue-getters.ts @@ -45,13 +45,6 @@ export class QueueGetters extends QueueBase { }); } - /** - * Helper to easily extend Job class calls. - */ - protected get Job(): typeof Job { - return Job; - } - private sanitizeJobTypes(types: JobType[] | JobType | undefined): JobType[] { const currentTypes = typeof types === 'string' ? [types] : types;