- From: Domenic Denicola <notifications@github.com>
- Date: Tue, 30 Jun 2015 01:10:01 -0700
- To: whatwg/streams <streams@noreply.github.com>
Received on Tuesday, 30 June 2015 08:10:33 UTC
> + if (stream._closeRequested) {
> + throw new TypeError('The stream has already been closed; do not close it again!');
> + }
> + if (stream._state !== 'readable') {
> + throw new TypeError('The stream is not in the readable state and cannot be closed');
> + }
> +
> + if (this._totalQueuedBytes > 0) {
> + this._closeRequested = true;
> +
> + return;
> + }
> +
> + const reader = stream._reader;
> +
> + if (reader === undefined || IsReadableByteStreamReader(reader)) {
I think the naming of IsReadableByteStreamReader is a bit confusing, even though it mirrors the getReader/getByobReader methods. Maybe IsReadableByteStreamDefaultReader?
---
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/streams/pull/361/files#r33549270
Received on Tuesday, 30 June 2015 08:10:33 UTC