Comparing version 3.1.5 to 3.1.6
@@ -0,1 +1,24 @@ | ||
## [3.1.6](https://github.com/kelektiv/node-cron/compare/v3.1.5...v3.1.6) (2023-10-29) | ||
### π Bug Fixes | ||
* revert runOnce breaking changes ([#760](https://github.com/kelektiv/node-cron/issues/760)) ([7cb53ec](https://github.com/kelektiv/node-cron/commit/7cb53ec9944b19ed5ba92b2466e73fc158ef1d11)) | ||
### βοΈ Continuous Integrations | ||
* **action:** update actions/checkout action to v4 ([#755](https://github.com/kelektiv/node-cron/issues/755)) ([d0d70c6](https://github.com/kelektiv/node-cron/commit/d0d70c67532b9a2563ed7a4273901f85b314d1b9)) | ||
* **action:** update github/codeql-action action to v2.22.4 ([#752](https://github.com/kelektiv/node-cron/issues/752)) ([04454c3](https://github.com/kelektiv/node-cron/commit/04454c34a5cbfcffb6938173393380840a7c8d75)) | ||
* **action:** update github/codeql-action action to v2.22.5 ([#758](https://github.com/kelektiv/node-cron/issues/758)) ([2dff183](https://github.com/kelektiv/node-cron/commit/2dff1838a6b8ee400ad721c7a41065ee73a42b8a)) | ||
* **action:** update ossf/scorecard-action action to v2.3.1 ([#754](https://github.com/kelektiv/node-cron/issues/754)) ([41d21f1](https://github.com/kelektiv/node-cron/commit/41d21f16b58dc76e48c81751c8782b6c6c1ac7ca)) | ||
### β»οΈ Chores | ||
* **deps:** update dependency [@commitlint](https://github.com/commitlint)/cli to v18.2.0 ([#759](https://github.com/kelektiv/node-cron/issues/759)) ([4cb466e](https://github.com/kelektiv/node-cron/commit/4cb466e183016861098cb4252b48cb54fb0ea96d)) | ||
* **deps:** update dependency [@types](https://github.com/types)/node to v20.8.8 ([#756](https://github.com/kelektiv/node-cron/issues/756)) ([361728e](https://github.com/kelektiv/node-cron/commit/361728ebf8bc6a3202001fccaf6661e9417054a1)) | ||
* **deps:** update dependency [@types](https://github.com/types)/node to v20.8.9 ([#757](https://github.com/kelektiv/node-cron/issues/757)) ([e2b1bac](https://github.com/kelektiv/node-cron/commit/e2b1bac21b59b9bd02a9000ec1c885961d07e121)) | ||
* **deps:** update dependency [@typescript-eslint](https://github.com/typescript-eslint)/eslint-plugin to v6.9.0 ([#753](https://github.com/kelektiv/node-cron/issues/753)) ([9cec04f](https://github.com/kelektiv/node-cron/commit/9cec04f1578f26f50d3e338ad3a9053ef74bbb01)) | ||
## [3.1.5](https://github.com/kelektiv/node-cron/compare/v3.1.4...v3.1.5) (2023-10-26) | ||
@@ -2,0 +25,0 @@ |
@@ -8,5 +8,5 @@ import { CronTime } from './time'; | ||
lastExecution: Date | null; | ||
runOnce: boolean; | ||
context: CronContext<C>; | ||
onComplete?: WithOnComplete<OC> extends true ? CronOnCompleteCallback : undefined; | ||
get runOnce(): boolean; | ||
private _timeout?; | ||
@@ -13,0 +13,0 @@ private _callbacks; |
@@ -8,5 +8,2 @@ "use strict"; | ||
class CronJob { | ||
get runOnce() { | ||
return this.cronTime.realDate; | ||
} | ||
constructor(cronTime, onTick, onComplete, start, timeZone, context, runOnInit, utcOffset, unrefTimeout) { | ||
@@ -16,2 +13,3 @@ this.running = false; | ||
this.lastExecution = null; | ||
this.runOnce = false; | ||
this._callbacks = []; | ||
@@ -37,2 +35,5 @@ this.context = (context !== null && context !== void 0 ? context : this); | ||
} | ||
if (this.cronTime.realDate) { | ||
this.runOnce = true; | ||
} | ||
this.addCallback(this._fnWrap(onTick)); | ||
@@ -87,2 +88,4 @@ if (runOnInit) { | ||
this.cronTime = time; | ||
if (time.realDate) | ||
this.runOnce = true; | ||
if (wasRunning) | ||
@@ -89,0 +92,0 @@ this.start(); |
{ | ||
"name": "cron", | ||
"description": "Cron jobs for your node", | ||
"version": "3.1.5", | ||
"version": "3.1.6", | ||
"author": "Nick Campbell <nicholas.j.campbell@gmail.com> (https://github.com/ncb000gt)", | ||
@@ -31,3 +31,3 @@ "bugs": { | ||
"devDependencies": { | ||
"@commitlint/cli": "18.0.0", | ||
"@commitlint/cli": "18.2.0", | ||
"@fast-check/jest": "1.7.3", | ||
@@ -43,5 +43,5 @@ "@insurgentlab/commitlint-config": "18.1.3", | ||
"@types/jest": "29.5.6", | ||
"@types/node": "20.8.7", | ||
"@types/node": "20.8.9", | ||
"@types/sinon": "10.0.20", | ||
"@typescript-eslint/eslint-plugin": "6.8.0", | ||
"@typescript-eslint/eslint-plugin": "6.9.0", | ||
"chai": "4.3.10", | ||
@@ -48,0 +48,0 @@ "eslint": "8.52.0", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
71835
923
0