Convert process.exit into return

This commit is contained in:
Luc Perkins 2024-06-03 17:04:55 -07:00
parent 4edd92a1a4
commit a13b1bda12
No known key found for this signature in database
GPG key ID: 16DB1108FB591835
3 changed files with 5 additions and 5 deletions

4
dist/index.js generated vendored
View file

@ -95537,7 +95537,7 @@ var MagicNixCacheAction = class extends DetSysAction {
core.warning( core.warning(
`skipping post phase due to error in main phase: ${this.errorInMain}` `skipping post phase due to error in main phase: ${this.errorInMain}`
); );
process.exit(0); return;
} }
if (this.alreadyRunning) { if (this.alreadyRunning) {
core.debug(TEXT_ALREADY_RUNNING); core.debug(TEXT_ALREADY_RUNNING);
@ -95656,7 +95656,7 @@ var MagicNixCacheAction = class extends DetSysAction {
const pidFile = external_node_path_namespaceObject.join(this.daemonDir, "daemon.pid"); const pidFile = external_node_path_namespaceObject.join(this.daemonDir, "daemon.pid");
await promises_namespaceObject.writeFile(pidFile, `${daemon.pid}`); await promises_namespaceObject.writeFile(pidFile, `${daemon.pid}`);
core.info("Waiting for magic-nix-cache to start..."); core.info("Waiting for magic-nix-cache to start...");
await new Promise((resolve, _reject) => { await new Promise((resolve) => {
notifyPromise.then((_value) => { notifyPromise.then((_value) => {
resolve(); resolve();
}).catch((e) => { }).catch((e) => {

2
dist/index.js.map generated vendored

File diff suppressed because one or more lines are too long

View file

@ -115,7 +115,7 @@ class MagicNixCacheAction extends DetSysAction {
actionsCore.warning( actionsCore.warning(
`skipping post phase due to error in main phase: ${this.errorInMain}`, `skipping post phase due to error in main phase: ${this.errorInMain}`,
); );
process.exit(0); return;
} }
if (this.alreadyRunning) { if (this.alreadyRunning) {
@ -264,7 +264,7 @@ class MagicNixCacheAction extends DetSysAction {
actionsCore.info("Waiting for magic-nix-cache to start..."); actionsCore.info("Waiting for magic-nix-cache to start...");
await new Promise<void>((resolve, _reject) => { await new Promise<void>((resolve) => {
notifyPromise notifyPromise
// eslint-disable-next-line github/no-then // eslint-disable-next-line github/no-then
.then((_value) => { .then((_value) => {