2
0

Fixed Jobs/StartNow

This commit is contained in:
glax 2023-09-02 14:49:31 +02:00
parent eebe25a378
commit ae5be31c89
2 changed files with 7 additions and 0 deletions

View File

@ -62,6 +62,12 @@ public abstract class Job : GlobalBase
this.lastExecution = DateTime.Now;
}
public void ExecuteNow()
{
ResetProgress();
this.lastExecution = DateTime.UnixEpoch;
}
public void Cancel()
{
Log($"Cancelling {this}");

View File

@ -130,6 +130,7 @@ public class JobBoss : GlobalBase
Queue<Job> connectorJobQueue = mangaConnectorJobQueue[job.mangaConnector];
if(!connectorJobQueue.Contains(job))
connectorJobQueue.Enqueue(job);
job.ExecuteNow();
}
public void AddJobsToQueue(IEnumerable<Job> jobs)