use addJobs

This commit is contained in:
mertalev
2025-04-30 20:13:40 -04:00
parent f0c013f844
commit e773a7b7a1
4 changed files with 41 additions and 18 deletions

View File

@@ -130,7 +130,7 @@ export class JobService extends BaseService {
return response;
}
private async start(name: QueueName, { force }: JobCommandDto): Promise<void> {
private async start(name: QueueName, { force }: JobCommandDto): Promise<unknown> {
const { active } = await this.jobRepository.getJobCounts(name);
if (active > 0) {
throw new BadRequestException(`Jobs are already running`);