Skip to content

Commit a1c652a

Browse files
cjihrigtargos
authored andcommitted
child_process: remove empty if condition
This commit replaces an empty if-else-if with a single if condition. PR-URL: #11427 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Michaël Zasso <targos@protonmail.com> Reviewed-By: Santiago Gimeno <santiago.gimeno@gmail.com>
1 parent 8629b33 commit a1c652a

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

lib/child_process.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -216,9 +216,7 @@ exports.execFile = function(file /*, args, options, callback*/) {
216216
stderr = Buffer.concat(_stderr);
217217
}
218218

219-
if (ex) {
220-
// Will be handled later
221-
} else if (code === 0 && signal === null) {
219+
if (!ex && code === 0 && signal === null) {
222220
callback(null, stdout, stderr);
223221
return;
224222
}

0 commit comments

Comments
 (0)