(key: string, value: string)
| 334 | } |
| 335 | |
| 336 | public writeHeader(key: string, value: string) { |
| 337 | if (this.isAborted) return; |
| 338 | |
| 339 | if (key === class="st">"Content-Length") { |
| 340 | class="cm">// the content length is automatically added by uWebSockets.js |
| 341 | return; |
| 342 | } |
| 343 | if (this.statusWritten) { |
| 344 | this.res.writeHeader(key, value); |
| 345 | } else { |
| 346 | this.headers.push([key, value]); |
| 347 | } |
| 348 | } |
| 349 | |
| 350 | private writeBufferedHeaders() { |
| 351 | this.headers.forEach(([key, value]) => { |
no outgoing calls
no test coverage detected