Skip to content

Commit

Permalink
Regression: Fix job Id not returned by agenda (#26315)
Browse files Browse the repository at this point in the history
  • Loading branch information
murtaza98 committed Jul 20, 2022
1 parent 3d989b6 commit 7422924
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/agenda/src/Agenda.ts
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ export class Agenda extends EventEmitter {

private async _createScheduledJob(when: string | Date, name: string, data: IJob['data']): Promise<Job> {
const job = this.create(name, data);
job.schedule(when).save();
await job.schedule(when).save();
return job;
}

Expand Down

0 comments on commit 7422924

Please sign in to comment.