fixed queue cleaner being triggered perpetually after each run (#15)

This commit is contained in:
Marius Nechifor
2024-11-25 21:53:17 +02:00
committed by GitHub
parent a0c8ff72fb
commit 53adb6c1c1
@@ -19,7 +19,7 @@ public class JobChainingListener : IJobListener
public async Task JobWasExecuted(IJobExecutionContext context, JobExecutionException? jobException, CancellationToken cancellationToken) public async Task JobWasExecuted(IJobExecutionContext context, JobExecutionException? jobException, CancellationToken cancellationToken)
{ {
if (string.IsNullOrEmpty(_nextJobName)) if (string.IsNullOrEmpty(_nextJobName) || context.JobDetail.Key.Name == _nextJobName)
{ {
return; return;
} }