Newer
Older
taehui / taehui-fe / src / app / www / forums / route.ts
@Taehui Taehui on 17 Mar 333 bytes 2024-03-17 오후 11:29
import logIP from "@/app/www/mws/logIP";
import { getForums } from "@/app/www/systems/forums";

export const GET = logIP(async (req) => {
  const language = req.nextUrl.searchParams.get("language");

  if (!language) {
    return Response.json(undefined, { status: 400 });
  }

  return Response.json(await getForums(language));
});