"use client";

import { authClient } from "@/lib/auth-client";
import { redirect } from "next/navigation";

export default function Logout() {
  const handleLogout = async () => {
    await authClient.signOut();
    redirect("/");
  };

  return <button onClick={handleLogout}>Logout</button>;
}
