import { NextResponse } from 'next/server';
import { clearSessionCookie } from '@/core/auth';
import { isNativeAuthEnabled } from '@/core/auth/standalone';

export async function POST(): Promise<NextResponse> {
  if (!isNativeAuthEnabled()) {
    return NextResponse.json({ error: 'Not found' }, { status: 404 });
  }
  const res = NextResponse.json({ ok: true });
  clearSessionCookie(res);
  return res;
}
