MCPcopy Index your code
hub / github.com/nodejs/llhttp / checkInvalidTransferEncoding

Method checkInvalidTransferEncoding

src/llhttp/http.ts:600–606  ·  view source on GitHub ↗
(otherwise: Node)

Source from the content-addressed store, hash-verified

598 * Since llhttp 9, we go for the stricter approach and treat this as an error.
599 */
600 const checkInvalidTransferEncoding = (otherwise: Node) => {
601 return this.testFlags(FLAGS.CONTENT_LENGTH, {
602 1: this.testLenientFlags(LENIENT_FLAGS.CHUNKED_LENGTH, {
603 0: p.error(ERROR.INVALID_TRANSFER_ENCODING, 'Transfer-Encoding can\'t be present with Content-Length'),
604 }).otherwise(otherwise),
605 }).otherwise(otherwise);
606 };
607
608 const checkInvalidContentLength = (otherwise: Node) => {
609 return this.testFlags(FLAGS.TRANSFER_ENCODING, {

Callers

nothing calls this directly

Calls 2

testFlagsMethod · 0.95
testLenientFlagsMethod · 0.95

Tested by

no test coverage detected