MCPcopy Create free account
hub / github.com/nodejs/undici / markInvalidCacheControlDirective

Function markInvalidCacheControlDirective

lib/util/cache.js:104–115  ·  view source on GitHub ↗
(directives, key)

Source from the content-addressed store, hash-verified

102}
103
104function markInvalidCacheControlDirective (directives, key) {
105 let invalidDirectives = directives[kInvalidCacheControlDirectives]
106
107 if (invalidDirectives === undefined) {
108 invalidDirectives = new Set()
109 Object.defineProperty(directives, kInvalidCacheControlDirectives, {
110 value: invalidDirectives
111 })
112 }
113
114 invalidDirectives.add(key)
115}
116
117function hasInvalidCacheControlDirective (directives, key) {
118 return directives[kInvalidCacheControlDirectives]?.has(key) === true

Callers 1

parseCacheControlHeaderFunction · 0.85

Calls 1

addMethod · 0.65

Tested by

no test coverage detected