Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

misc: addressed module issue

Sheen Capadngana7b25f3bd8d0
diff --git a/backend/src/services/identity-jwt-auth/identity-jwt-auth-service.ts b/backend/src/services/identity-jwt-auth/identity-jwt-auth-service.ts
index 73cb0090d3..aca96c1453 100644
--- a/backend/src/services/identity-jwt-auth/identity-jwt-auth-service.ts
+++ b/backend/src/services/identity-jwt-auth/identity-jwt-auth-service.ts
@@ -1,6 +1,6 @@
import { ForbiddenError } from "@casl/ability";
import https from "https";
-import jwt, { JsonWebTokenError } from "jsonwebtoken";
+import jwt from "jsonwebtoken";
import { JwksClient } from "jwks-rsa";
import { IdentityAuthMethod, TIdentityJwtAuthsUpdate } from "@app/db/schemas";
@@ -113,7 +113,7 @@ export const identityJwtAuthServiceFactory = ({
tokenData = jwt.verify(jwtValue, publicKey) as Record<string, string>;
isMatchAnyKey = true;
} catch (error) {
- if (error instanceof JsonWebTokenError) {
+ if (error instanceof jwt.JsonWebTokenError) {
errors.push(error.message);
}
}