From bdfdb674495922cb0454f3ffa8cbcd7a34f1ab15 Mon Sep 17 00:00:00 2001 From: Vins Date: Mon, 11 Dec 2023 17:52:24 +0100 Subject: [PATCH 1/2] redeploy --- src/middleware.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/middleware.ts b/src/middleware.ts index 2d1098bc..39b4491e 100644 --- a/src/middleware.ts +++ b/src/middleware.ts @@ -12,7 +12,7 @@ export async function middleware(request: NextRequest) { const userDecodedToken = jwt_decode(cookies.value) as IUserJwtPayload; const customerDecodedToken = jwt_decode(cookies.value) as ICustomerJwtPayload; - // If no JWT provided, redirect to login page. + // If no JWT provided, redirect to login page if (!userDecodedToken && !customerDecodedToken) return NextResponse.redirect(new URL("/login", request.url)); // If JWT expired, redirect to login callback page to refresh tokens From ee4476e28f6984f53587d16b1847cde0bbd9d8f0 Mon Sep 17 00:00:00 2001 From: Vins Date: Mon, 11 Dec 2023 17:58:21 +0100 Subject: [PATCH 2/2] debug finished --- src/front/Components/Layouts/Login/index.tsx | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/front/Components/Layouts/Login/index.tsx b/src/front/Components/Layouts/Login/index.tsx index 884c4ae8..b5da5a40 100644 --- a/src/front/Components/Layouts/Login/index.tsx +++ b/src/front/Components/Layouts/Login/index.tsx @@ -21,8 +21,6 @@ export default function Login() { const redirectUserOnConnection = useCallback(() => { const variables = FrontendVariables.getInstance(); - console.log(variables); - router.push( `${variables.IDNOT_BASE_URL + variables.IDNOT_AUTHORIZE_ENDPOINT}?client_id=${variables.IDNOT_CLIENT_ID}&redirect_uri=${ variables.FRONT_APP_HOST