Comparing version 3.1.2 to 3.1.3
@@ -112,3 +112,3 @@ import process from 'node:process'; | ||
export function asyncExitHook(onExit, options) { | ||
export function asyncExitHook(onExit, options = {}) { | ||
if (typeof onExit !== 'function') { | ||
@@ -118,3 +118,3 @@ throw new TypeError('onExit must be a function'); | ||
if (typeof options?.minimumWait !== 'number' || options.minimumWait <= 0) { | ||
if (!(typeof options.minimumWait === 'number' && options.minimumWait > 0)) { | ||
throw new TypeError('minimumWait must be set to a positive numeric value'); | ||
@@ -121,0 +121,0 @@ } |
{ | ||
"name": "exit-hook", | ||
"version": "3.1.2", | ||
"version": "3.1.3", | ||
"description": "Run some code when the process exits", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
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
10932