MCPcopy
hub / github.com/sindresorhus/got / hasHttpProtocolWithoutSlashes

Function hasHttpProtocolWithoutSlashes

source/core/options.ts:953–953  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

951const hasProtocolSlashes = (value: string): boolean => /^[a-z][\d+\-.a-z]*:\/\//iv.test(value);
952
953const hasHttpProtocolWithoutSlashes = (value: string): boolean => /^https?:(?!\/\/)/iv.test(value);
954
955const hasUnixProtocolWithoutSlashes = (value: string): boolean => /^unix:/iv.test(value);
956

Callers 2

urlMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…