14 lines
417 B
TypeScript
14 lines
417 B
TypeScript
import { getServerSession } from "next-auth/next";
|
|
import { authOptions } from "@/app/api/auth/[...nextauth]/route";
|
|
import { redirect } from "next/navigation";
|
|
import { TimeTrackerFrame } from "@/components/timetracker/timetracker-frame";
|
|
|
|
export default async function Page() {
|
|
const session = await getServerSession(authOptions);
|
|
|
|
if (!session) {
|
|
redirect("/signin");
|
|
}
|
|
|
|
return <TimeTrackerFrame />;
|
|
}
|