| 2973 | } |
| 2974 | } |
| 2975 | onResponseData(chunk) { |
| 2976 | assert(!this.aborted); |
| 2977 | assert(!this.completed); |
| 2978 | if (channels.bodyChunkReceived.hasSubscribers) { |
| 2979 | channels.bodyChunkReceived.publish({ request: this, chunk }); |
| 2980 | } |
| 2981 | const controller = this[kController]; |
| 2982 | try { |
| 2983 | this[kHandler].onResponseData?.(controller, chunk); |
| 2984 | return !controller?.paused; |
| 2985 | } catch (err) { |
| 2986 | this.abort(err); |
| 2987 | return false; |
| 2988 | } |
| 2989 | } |
| 2990 | onRequestUpgrade(statusCode, headers, socket) { |
| 2991 | assert(!this.aborted); |
| 2992 | assert(!this.completed); |