diff options
Diffstat (limited to 'ext/cache')
-rw-r--r-- | ext/cache/01_cache.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/ext/cache/01_cache.js b/ext/cache/01_cache.js index e64178d89..d3514a3f2 100644 --- a/ext/cache/01_cache.js +++ b/ext/cache/01_cache.js @@ -8,6 +8,7 @@ const { StringPrototypeSplit, StringPrototypeTrim, Symbol, + SymbolFor, TypeError, } = primordials; import { @@ -59,6 +60,10 @@ class CacheStorage { cacheName = webidl.converters["DOMString"](cacheName, prefix, "Argument 1"); return await op_cache_storage_delete(cacheName); } + + [SymbolFor("Deno.privateCustomInspect")](inspect, inspectOptions) { + return `${this.constructor.name} ${inspect({}, inspectOptions)}`; + } } const _matchAll = Symbol("[[matchAll]]"); @@ -275,6 +280,10 @@ class Cache { return responses; } + + [SymbolFor("Deno.privateCustomInspect")](inspect, inspectOptions) { + return `${this.constructor.name} ${inspect({}, inspectOptions)}`; + } } webidl.configureInterface(CacheStorage); |