MCPcopy
hub / github.com/axios/axios / maybeWithAuthCredentials

Function maybeWithAuthCredentials

lib/adapters/fetch.js:59–66  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

57};
58
59const maybeWithAuthCredentials = (url) => {
60 const protocolIndex = url.indexOf('://');
61 let urlToCheck = url;
62 if (protocolIndex !== -1) {
63 urlToCheck = urlToCheck.slice(protocolIndex + 3);
64 }
65 return urlToCheck.includes('@') || urlToCheck.includes(':');
66};
67
68const factory = (env) => {
69 const globalObject =

Callers 1

factoryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected