- From: Adam Rice <notifications@github.com>
- Date: Sun, 09 Apr 2017 23:08:51 -0700
- To: whatwg/streams <streams@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Monday, 10 April 2017 06:09:28 UTC
ReadableStream pipeTo() was using instanceof to distinguish Promises from non-promises. However, this can be fooled by Object.create(Promise). Use the brand-check performed by Promise.prototype.then() for the check instead. The test for this is in https://github.com/w3c/web-platform-tests/pull/5519. You can view, comment on, or merge this pull request online at: https://github.com/whatwg/streams/pull/730 -- Commit Summary -- * Use Promise.prototype.then brand check to detect real Promise -- File Changes -- M reference-implementation/lib/readable-stream.js (16) M reference-implementation/web-platform-tests (2) -- Patch Links -- https://github.com/whatwg/streams/pull/730.patch https://github.com/whatwg/streams/pull/730.diff -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/whatwg/streams/pull/730
Received on Monday, 10 April 2017 06:09:28 UTC