http: remove redundant condition

`conn.destroyed` is guaranteed to be `false` because a previous `if`
statement already handles the case where `conn && conn.destroyed`
evaluates to `true` returning `false` in that case.

PR-URL: https://github.com/nodejs/node/pull/29078
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
Luigi Pinca authored and Michaël Zasso committed 2019-08-19 21:19:00 +02:00
1 parent 1011a1792c
commit 2e5008848e
1 file changed
+1 -1
+1 -1
View File
@@ -285,7 +285,7 @@ function _writeRaw(data, encoding, callback) {
encoding = null;
}
if (conn && conn._httpMessage === this && conn.writable && !conn.destroyed) {
if (conn && conn._httpMessage === this && conn.writable) {
// There might be pending data in the this.output buffer.
if (this.outputData.length) {
this._flushOutput(conn);