Fix uniq tasks start time

This commit is contained in:
Anton Vakhrushev 2020-04-04 15:58:06 +03:00
parent 153e31463c
commit bf7f4c1b7d

View File

@ -47,7 +47,7 @@ export class Scheduler {
private scheduleUniqTask(seconds: number, name: string, args: Args = {}) { private scheduleUniqTask(seconds: number, name: string, args: Args = {}) {
const taskScheduler = () => { const taskScheduler = () => {
if (!this.taskQueue.hasNamed(name)) { if (!this.taskQueue.hasNamed(name)) {
this.taskQueue.push(new Command(name, args), timestamp()); this.taskQueue.push(new Command(name, args), timestamp() + 10 * 60);
} }
}; };
taskScheduler(); taskScheduler();