diff --git a/lib/internal/streams/destroy.js b/lib/internal/streams/destroy.js index 10f5471e21d3eb..5c352135dc3012 100644 --- a/lib/internal/streams/destroy.js +++ b/lib/internal/streams/destroy.js @@ -319,7 +319,7 @@ function destroyer(stream, err) { // TODO: Don't lose err? stream.close(); } else if (err) { - process.nextTick(emitErrorCloseLegacy, stream); + process.nextTick(emitErrorCloseLegacy, stream, err); } else { process.nextTick(emitCloseLegacy, stream); }