a tool for shared writing and social publishing
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

add message to wrong auth redirects

+2 -2
+2 -2
middleware.ts
··· 90 90 let signature = req.nextUrl.searchParams.get("signature"); 91 91 92 92 if (typeof payload !== "string" || typeof signature !== "string") 93 - return new NextResponse(null, { status: 401 }); 93 + return new NextResponse("Payload or Signature not string", { status: 401 }); 94 94 95 95 let verifySig = await signCrossSiteToken(decodeURIComponent(payload)); 96 96 if (verifySig !== decodeURIComponent(signature)) 97 - return new NextResponse(null, { status: 401 }); 97 + return new NextResponse("Incorrect Signature", { status: 401 }); 98 98 99 99 let token: CROSS_SITE_AUTH_REQUEST = JSON.parse(atob(payload)); 100 100 let auth_token = req.cookies.get("auth_token")?.value || null;