generated from tailored/router-template
update time
This commit is contained in:
@@ -14,7 +14,7 @@ class TimeRecorder {
|
||||
endTime: number;
|
||||
duration: number;
|
||||
updateTime: number;
|
||||
maxDuration: number = 40 * 1000; // 30s;
|
||||
maxDuration: number = 30 * 1000; // 30s;
|
||||
constructor() {
|
||||
const now = Date.now();
|
||||
this.startTime = now;
|
||||
@@ -105,6 +105,7 @@ worker.on('completed', async (job) => {
|
||||
const nextTime = up.nextTime + getTimeDuration();
|
||||
const unread = await queue.getJob('unread');
|
||||
if (!unread) {
|
||||
console.log('====add unread next-time', nextTime, getTimeDuration());
|
||||
addUnreadTask(nextTime);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user