@astratra/security 1.12.0 → 1.12.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/idTokens.js +1 -1
package/package.json
CHANGED
package/src/idTokens.js
CHANGED
|
@@ -100,7 +100,7 @@ function createIdTokenVerifier(options = {}) {
|
|
|
100
100
|
attemptedAt = now();
|
|
101
101
|
let body;
|
|
102
102
|
try {
|
|
103
|
-
const signal = typeof AbortSignal
|
|
103
|
+
const signal = typeof globalThis.AbortSignal?.timeout === 'function' ? globalThis.AbortSignal.timeout(timeoutMs) : undefined;
|
|
104
104
|
const response = await fetchImpl(jwksUrl, signal ? { signal } : undefined);
|
|
105
105
|
if (!response || !response.ok) throw new Error('status');
|
|
106
106
|
body = await response.json();
|