migrate / index page (#18960)

This commit is contained in:
Benny Joo
2025-01-28 20:33:00 +01:00
committed by GitHub
parent ce4c9dfc9a
commit 377d4e5bfd
3 changed files with 1 additions and 19 deletions
+1
View File
@@ -140,6 +140,7 @@ export const config = {
// Next.js Doesn't support spread operator in config matcher, so, we must list all paths explicitly here.
// https://github.com/vercel/next.js/discussions/42458
matcher: [
"/",
"/403",
"/500",
"/icons",
-19
View File
@@ -1,19 +0,0 @@
import type { GetServerSidePropsContext } from "next";
import { getServerSession } from "@calcom/features/auth/lib/getServerSession";
function RedirectPage() {
return;
}
export async function getServerSideProps({ req, res }: GetServerSidePropsContext) {
const session = await getServerSession({ req, res });
if (!session?.user?.id) {
return { redirect: { permanent: false, destination: "/auth/login" } };
}
return { redirect: { permanent: false, destination: "/event-types" } };
}
export default RedirectPage;