mirror of
https://github.com/LukeHagar/better-auth.git
synced 2025-12-10 12:27:44 +00:00
11 lines
285 B
TypeScript
11 lines
285 B
TypeScript
import { auth } from "@/lib/auth";
|
|
import { toNextJsHandler } from "better-auth/next-js";
|
|
import { NextRequest } from "next/server";
|
|
|
|
export const { GET } = toNextJsHandler(auth);
|
|
|
|
export const POST = async (req: NextRequest) => {
|
|
const res = await auth.handler(req);
|
|
return res;
|
|
};
|