Skip to content

Commit

Permalink
fixuP
Browse files Browse the repository at this point in the history
  • Loading branch information
ronag committed Jul 7, 2021
1 parent 37f31ad commit f1c5c10
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/internal/streams/readable.js
Original file line number Diff line number Diff line change
Expand Up @@ -1113,8 +1113,10 @@ async function* createAsyncIterator(stream, options) {
const chunk = stream.destroyed ? null : stream.read();
if (chunk !== null) {
yield chunk;
} else if (error !== undefined) {
break;
} else if (error) {
throw error;
} else if (error === null) {
return;
} else {
await new Promise(next);
}
Expand Down

0 comments on commit f1c5c10

Please sign in to comment.