http: remove unnecessary check
authorBrian White <mscdex@mscdex.net>
Mon, 15 Feb 2016 09:47:06 +0000 (04:47 -0500)
committerMyles Borins <mborins@us.ibm.com>
Mon, 21 Mar 2016 19:57:55 +0000 (12:57 -0700)
The value passed to `process.nextTick()` which is passed to the
callback is already a valid object, so the conditional will always
evaluate to true.

PR-URL: https://github.com/nodejs/node/pull/5233
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
lib/_http_outgoing.js

index 47c6f93..654e85a 100644 (file)
@@ -493,8 +493,7 @@ function writeAfterEndNT(self, err, callback) {
 
 
 function connectionCorkNT(conn) {
-  if (conn)
-    conn.uncork();
+  conn.uncork();
 }