diff --git a/src/JWT.ts b/src/JWT.ts index 7c4e8879..4cf6fc99 100644 --- a/src/JWT.ts +++ b/src/JWT.ts @@ -198,8 +198,8 @@ export function decodeJWT(jwt: string, recurse = true): JWTDecoded { return innerDecodedJwt } return decodedJwt - } catch (e) { - throw new Error('invalid_argument: Incorrect format JWT') + } catch (e: any) { + throw new Error(`invalid_argument: ${JWT_ERROR.INVALID_JWT}: ${e}`) } }