mirror of
https://github.com/sern-handler/handler
synced 2026-06-06 01:16:55 +00:00
Update cleanup.ts
This commit is contained in:
@@ -23,7 +23,7 @@ export function removeCleanupListener(listener: CleanupListener): boolean {
|
|||||||
|
|
||||||
/** Executes all cleanup listeners and then exits the process. Call this instead of `process.exit` to ensure all listeners are fully executed. */
|
/** Executes all cleanup listeners and then exits the process. Call this instead of `process.exit` to ensure all listeners are fully executed. */
|
||||||
export async function exitAfterCleanup(code = 0): Promise<never> {
|
export async function exitAfterCleanup(code = 0): Promise<never> {
|
||||||
await executeCleanupListeners(code);
|
await executeCleanupListeners();
|
||||||
process.exit(code);
|
process.exit(code);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user