MCPcopy Index your code
hub / github.com/di-sukharev/opencommit / removeHTTPWhitespace

Function removeHTTPWhitespace

out/cli.cjs:51696–51706  ·  view source on GitHub ↗
(str2, leading = true, trailing = true)

Source from the content-addressed store, hash-verified

51694 }
51695 serialization += value;
51696 }
51697 return serialization;
51698 }
51699 function isHTTPWhiteSpace(char) {
51700 return char === "\r" || char === "\n" || char === " " || char === " ";
51701 }
51702 function removeHTTPWhitespace(str2, leading = true, trailing = true) {
51703 let lead = 0;
51704 let trail = str2.length - 1;
51705 if (leading) {
51706 for (; lead < str2.length && isHTTPWhiteSpace(str2[lead]); lead++) ;
51707 }
51708 if (trailing) {
51709 for (; trail > 0 && isHTTPWhiteSpace(str2[trail]); trail--) ;

Callers 1

parseMIMETypeFunction · 0.85

Calls 2

isHTTPWhiteSpaceFunction · 0.85
sliceMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…