node: stream.finished: err is optional

This commit is contained in:
Piotr Roszatycki
2018-09-13 10:08:55 +02:00
parent f4b9e5acaa
commit a649bec809
2 changed files with 3 additions and 3 deletions

View File

@@ -1124,10 +1124,10 @@ function simplified_stream_ctor_test() {
}
function streamPipelineFinished() {
const cancel = stream.finished(process.stdin, (err: Error) => {});
const cancel = stream.finished(process.stdin, (err?: Error) => {});
cancel();
stream.pipeline(process.stdin, process.stdout, (err: Error) => {});
stream.pipeline(process.stdin, process.stdout, (err?: Error) => {});
}
async function asyncStreamPipelineFinished() {