fix: get env variable dynamically to avoid secret leakage

This commit is contained in:
Raul Lugo
2026-01-28 02:17:06 +01:00
parent 4abf69844a
commit 4e33401387
10 changed files with 238 additions and 58 deletions

View File

@@ -40,7 +40,7 @@ export async function signPayload(
return `${payloadB64u}.${sigB64u}`;
}
export async function verifyAndDecode<T = any>(
export async function verifyAndDecode<T = unknown>(
token: string,
secret: string,
): Promise<{ valid: boolean; payload?: T }> {