From 4e3731c7e7c02bd208e2baa981ea9bc1f6ae91fa Mon Sep 17 00:00:00 2001 From: cjihrig Date: Wed, 26 Oct 2016 22:41:24 -0400 Subject: [PATCH] child_process: remove unreachable code _convertCustomFds() is only called from normalizeSpawnArguments(), which always provides an options object. Therefore, there is no need to check for options in _convertCustomFds(). PR-URL: https://github.com/nodejs/node/pull/9307 Reviewed-By: Rich Trott Reviewed-By: Santiago Gimeno Reviewed-By: James M Snell --- lib/child_process.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/child_process.js b/lib/child_process.js index 4c2fb7e098..afdc5ae551 100644 --- a/lib/child_process.js +++ b/lib/child_process.js @@ -305,7 +305,7 @@ var _deprecatedCustomFds = internalUtil.deprecate(function(options) { 'Use options.stdio instead.'); function _convertCustomFds(options) { - if (options && options.customFds && !options.stdio) { + if (options.customFds && !options.stdio) { _deprecatedCustomFds(options); } }