File: 6461.patch

package info (click to toggle)
npm 9.2.0~ds1-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 319,300 kB
  • sloc: javascript: 166,731; sh: 194; makefile: 52; perl: 11
file content (23 lines) | stat: -rw-r--r-- 657 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
From: =?utf-8?q?Bitard_Micha=C3=ABl?= <bitard.michael@gmail.com>
Date: Wed, 17 May 2023 17:04:16 +0200
Subject: [PATCH] fix: exit code on workspace properly propagated in node v20

---
 lib/utils/exit-handler.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/utils/exit-handler.js b/lib/utils/exit-handler.js
index a9e061d..654f0ca 100644
--- a/lib/utils/exit-handler.js
+++ b/lib/utils/exit-handler.js
@@ -134,8 +134,8 @@ const exitHandler = err => {
     log.level = level
   }
 
-  let exitCode
-  let noLogMessage
+  let exitCode = process.exitCode || 0
+  let noLogMessage = exitCode !== 0
   let jsonError
 
   if (err) {