We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
/error
1 parent a5e0db4 commit 326eadfCopy full SHA for 326eadf
packages/core/src/lib/routes/shared.ts
@@ -7,15 +7,16 @@ export async function handleAuthorized(
7
params: any,
8
{ url, logger, callbacks: { signIn } }: InternalOptions
9
) {
10
- url.pathname += "/error"
11
try {
12
const authorized = await signIn(params)
13
if (!authorized) {
+ url.pathname += "/error"
14
logger.debug("User not authorized", params)
15
url.searchParams.set("error", "AccessDenied")
16
return { status: 403 as const, redirect: url.toString() }
17
}
18
} catch (e) {
19
20
const error = new AuthorizedCallbackError(e as Error)
21
logger.error(error)
22
url.searchParams.set("error", "Configuration")
0 commit comments