From 0a3e39ad904e041faa688a072558e4b778faf8f9 Mon Sep 17 00:00:00 2001 From: kirinnee Date: Sat, 11 Nov 2023 22:48:56 +0800 Subject: [PATCH] feat: print secret on sever-side logs --- src/routes/+layout.server.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/routes/+layout.server.ts b/src/routes/+layout.server.ts index 7cc972d..cd0eaab 100644 --- a/src/routes/+layout.server.ts +++ b/src/routes/+layout.server.ts @@ -5,10 +5,13 @@ import { expired, toResult } from "$lib/utility"; import jwtDecode from "jwt-decode"; import type { JWT } from "@auth/core/jwt"; import { redirect } from "@sveltejs/kit"; +import { config } from "../config/server"; export const load: LayoutServerLoad = async ({ locals, route }) => { const session: Session | null = await locals.getSession(); + console.log(config); + const signIn = session?.user != null && (session.access_token == null || expired(session.access_token, new Date()));