12 lines
328 B
TypeScript
12 lines
328 B
TypeScript
import { completeAuthorizationCallback, redirectToLoginWithError } from "@/lib/server/auth/oauth";
|
|
|
|
export const runtime = "nodejs";
|
|
|
|
export async function GET(request: Request) {
|
|
try {
|
|
return await completeAuthorizationCallback(request);
|
|
} catch {
|
|
return redirectToLoginWithError(request, "callback_failed");
|
|
}
|
|
}
|