(chunk, encoding, callback)
| 5894 | this.#zlibOptions = zlibOptions; |
| 5895 | } |
| 5896 | _transform(chunk, encoding, callback) { |
| 5897 | if (!this._inflateStream) { |
| 5898 | if (chunk.length === 0) { |
| 5899 | callback(); |
| 5900 | return; |
| 5901 | } |
| 5902 | this._inflateStream = (chunk[0] & 15) === 8 ? zlib.createInflate(this.#zlibOptions) : zlib.createInflateRaw(this.#zlibOptions); |
| 5903 | this._inflateStream.on("data", this.push.bind(this)); |
| 5904 | this._inflateStream.on("end", () => this.push(null)); |
| 5905 | this._inflateStream.on("error", (err) => this.destroy(err)); |
| 5906 | } |
| 5907 | this._inflateStream.write(chunk, encoding, callback); |
| 5908 | } |
| 5909 | _final(callback) { |
| 5910 | if (this._inflateStream) { |
| 5911 | this._inflateStream.end(); |
nothing calls this directly
no test coverage detected