Skip to content

Commit

Permalink
Expiry not set when updating cache response
Browse files Browse the repository at this point in the history
  • Loading branch information
ignoramous authored Jan 27, 2022
1 parent 5f84b7d commit bcec8e5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plugins/dns-operation/dnsResolver.js
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ DNSResolver.prototype.resolveDnsFromCache = async function (rxid, packet) {
throw new Error("resolver: cache miss");
}

cacheutil.updatedAnswer(cr.dnsPacket, packet.id);
cacheutil.updatedAnswer(cr.dnsPacket, packet.id, cr.metadata.expiry);
const b = dnsutil.encode(cr.dnsPacket);

return new Response(b, { headers: cacheutil.cacheHeaders() });
Expand Down

0 comments on commit bcec8e5

Please sign in to comment.