Skip to content

Commit

Permalink
fix missing agent (#103)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamjmcgrath authored Apr 14, 2023
2 parents 8203ceb + d5d6570 commit bb43017
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/access-token-jwt/src/get-key-fn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,11 @@ export type JWKSOptions = Required<
Pick<JwtVerifierOptions, 'agent' | 'secret'>;

export default ({
secret,
agent,
cooldownDuration,
timeoutDuration,
cacheMaxAge,
secret
}: JWKSOptions) => {
let getKeyFn: GetKeyFn;
let prevjwksUri: string;
Expand All @@ -28,6 +29,7 @@ export default ({
if (!getKeyFn || prevjwksUri !== jwksUri) {
prevjwksUri = jwksUri;
getKeyFn = createRemoteJWKSet(new URL(jwksUri), {
agent,
cooldownDuration,
timeoutDuration,
cacheMaxAge,
Expand Down

0 comments on commit bb43017

Please sign in to comment.