()
| 105 | let consumed = false; |
| 106 | |
| 107 | async function* iterLines(): AsyncGenerator<string, void, unknown> { |
| 108 | const lineDecoder = new LineDecoder(); |
| 109 | |
| 110 | const iter = readableStreamAsyncIterable<Bytes>(readableStream); |
| 111 | for await (const chunk of iter) { |
| 112 | for (const line of lineDecoder.decode(chunk)) { |
| 113 | yield line; |
| 114 | } |
| 115 | } |
| 116 | |
| 117 | for (const line of lineDecoder.flush()) { |
| 118 | yield line; |
| 119 | } |
| 120 | } |
| 121 | |
| 122 | async function* iterator(): AsyncIterator<Item, any, undefined> { |
| 123 | if (consumed) { |
nothing calls this directly
no test coverage detected