(stream2, err)
| 1334 | return body && !!(body.destroyed || body[kDestroyed] || ((_a = stream.isDestroyed) == null ? void 0 : _a.call(stream, body))); |
| 1335 | } |
| 1336 | function destroy(stream2, err) { |
| 1337 | if (stream2 == null || !isStream(stream2) || isDestroyed(stream2)) { |
| 1338 | return; |
| 1339 | } |
| 1340 | if (typeof stream2.destroy === "function") { |
| 1341 | if (Object.getPrototypeOf(stream2).constructor === IncomingMessage) { |
| 1342 | stream2.socket = null; |
| 1343 | } |
| 1344 | stream2.destroy(err); |
| 1345 | } else if (err) { |
| 1346 | queueMicrotask(() => { |
| 1347 | stream2.emit("error", err); |
| 1348 | }); |
| 1349 | } |
| 1350 | if (stream2.destroyed !== true) { |
| 1351 | stream2[kDestroyed] = true; |
| 1352 | } |
| 1353 | } |
| 1354 | var KEEPALIVE_TIMEOUT_EXPR = /timeout=(\d+)/; |
| 1355 | function parseKeepAliveTimeout(val) { |
| 1356 | const m = val.toString().match(KEEPALIVE_TIMEOUT_EXPR); |
no test coverage detected