MCPcopy Create free account
hub / github.com/nodejs/node / isValidReasonPhrase

Function isValidReasonPhrase

deps/undici/undici.js:5315–5325  ·  view source on GitHub ↗
(statusText)

Source from the content-addressed store, hash-verified

5313 }
5314 __name(isErrorLike, "isErrorLike");
5315 function isValidReasonPhrase(statusText) {
5316 for (let i = 0; i < statusText.length; ++i) {
5317 const c = statusText.charCodeAt(i);
5318 if (!(c === 9 || // HTAB
5319 c >= 32 && c <= 126 || // SP / VCHAR
5320 c >= 128 && c <= 255)) {
5321 return false;
5322 }
5323 }
5324 return true;
5325 }
5326 __name(isValidReasonPhrase, "isValidReasonPhrase");
5327 var isValidHeaderName = isValidHTTPToken;
5328 function isValidHeaderValue(potentialValue) {

Callers 1

initializeResponseFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected