We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d4c3a1f commit 39a70c4Copy full SHA for 39a70c4
1 file changed
lib/internal/streams/body.js
@@ -210,6 +210,13 @@ class Body {
210
return this[kState].readable !== null;
211
}
212
213
+ async promise() {
214
+ // eslint-disable-next-line no-unused-vars
215
+ for await (const chunk of this.readableNodeStream()) {
216
+ // Do nothing..
217
+ }
218
219
+
220
readableNodeStream() {
221
const { readable } = this[kState];
222
0 commit comments