diff options
| author | eug-vs <eug-vs@keemail.me> | 2020-12-02 05:15:49 +0300 | 
|---|---|---|
| committer | eug-vs <eug-vs@keemail.me> | 2020-12-02 05:15:49 +0300 | 
| commit | 10433d9d37452ed453272e12acc6012c1c15229d (patch) | |
| tree | df26caa44b1c70623518542eba122efb28a9238e | |
| parent | 4d35fe77fec445c3606adf383967ba1ddfcbdb56 (diff) | |
| download | mongo-cronjob-10433d9d37452ed453272e12acc6012c1c15229d.tar.gz | |
fix: stop all jobs along with polling
| -rw-r--r-- | lib/scheduler.ts | 3 | 
1 files changed, 2 insertions, 1 deletions
| diff --git a/lib/scheduler.ts b/lib/scheduler.ts index d6b28e9..e1437bd 100644 --- a/lib/scheduler.ts +++ b/lib/scheduler.ts @@ -31,9 +31,10 @@ class Scheduler {    public startPolling() {      this.pollingJob.start();    } -   +    public stopPolling() {      this.pollingJob.stop(); +    this.stopAllJobs();    }    private startAllJobs() { | 
