Skip to content

Commit

Permalink
fix: scheduled git sync task (#4481)
Browse files Browse the repository at this point in the history
Signed-off-by: Paul Saunders <[email protected]>

Co-authored-by: Rainshaw <[email protected]>
  • Loading branch information
pms1969 and Rainshaw authored Sep 25, 2021
1 parent 1dc9742 commit 66bf914
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions server/core/scheduler.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ class Job {
if (this.immediate) {
this.invoke(data)
} else {
this.queue(data)
this.enqueue(data)
}
}

Expand All @@ -41,7 +41,7 @@ class Job {
*
* @param {Object} data Job Data
*/
queue(data) {
enqueue(data) {
this.timeout = setTimeout(this.invoke.bind(this), this.schedule.asMilliseconds(), data)
}

Expand Down Expand Up @@ -85,7 +85,7 @@ class Job {
WIKI.logger.warn(err)
}
if (this.repeat && this.queue.jobs.includes(this)) {
this.queue(data)
this.enqueue(data)
} else {
this.stop().catch(() => {})
}
Expand Down

0 comments on commit 66bf914

Please sign in to comment.