From f15587e1d6ded3a23b2b17dda3f2980fee6c3a9a Mon Sep 17 00:00:00 2001 From: Chris Griffing Date: Sat, 26 Oct 2024 16:41:28 -0700 Subject: [PATCH] chore: prod jwt debugging --- playgrounds/app/src/lib/jwt.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/playgrounds/app/src/lib/jwt.ts b/playgrounds/app/src/lib/jwt.ts index 7ac63be..6b63f58 100644 --- a/playgrounds/app/src/lib/jwt.ts +++ b/playgrounds/app/src/lib/jwt.ts @@ -3,8 +3,12 @@ import jwt from 'jsonwebtoken' const TOKEN_SIGNING_KEY = process.env.TOKEN_SIGNING_KEY! +console.log('Has quotes', TOKEN_SIGNING_KEY.matchAll(/"/g)) + export function decodeToken(token: string) { - return jwt.verify(token, TOKEN_SIGNING_KEY, { algorithms: ['RS512'] }) + return jwt.verify(token, TOKEN_SIGNING_KEY, { + algorithms: ['RS512'], + }) } function encodeToken(