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

Method get

source/core/options.ts:3421–3432  ·  view source on GitHub ↗
(target, property, receiver)

Source from the content-addressed store, hash-verified

3419 #createHeadersProxy(): Headers {
3420 return new Proxy(this.#internals.headers, {
3421 get(target, property, receiver): unknown {
3422 if (typeof property === 'string') {
3423 if (Reflect.has(target, property)) {
3424 return Reflect.get(target, property, receiver);
3425 }
3426
3427 const normalizedProperty = property.toLowerCase();
3428 return Reflect.get(target, normalizedProperty, receiver);
3429 }
3430
3431 return Reflect.get(target, property, receiver);
3432 },
3433 set: (target, property, value): boolean => {
3434 if (typeof property === 'string') {
3435 const normalizedProperty = property.toLowerCase();

Callers 15

paginateFunction · 0.45
parseBodyFunction · 0.45
getFunction · 0.45
arguments.tsFile · 0.45
cache.tsFile · 0.45
http.tsFile · 0.45
post.tsFile · 0.45
prepareServerFunction · 0.45
abort.tsFile · 0.45

Calls 1

hasMethod · 0.80

Tested by

no test coverage detected