*Fix cache id generation
This commit is contained in:
parent
e5f02c413b
commit
512b85aa55
|
@ -15,8 +15,8 @@ export async function resolve(
|
||||||
options?: ResolverOptions,
|
options?: ResolverOptions,
|
||||||
bypassCache = false
|
bypassCache = false
|
||||||
): Promise<DNSResult | Error> {
|
): Promise<DNSResult | Error> {
|
||||||
let cacheId = `${domain}:{${blake2b(
|
let cacheId = `${domain}:${bufToHex(
|
||||||
new TextEncoder().encode(JSON.stringify(options))
|
blake2b(new TextEncoder().encode(JSON.stringify(options)))
|
||||||
)}`;
|
)}`;
|
||||||
|
|
||||||
if (cache.has(cacheId)) {
|
if (cache.has(cacheId)) {
|
||||||
|
|
Reference in New Issue