From 015edd3c9b0adddfe3c3fec8f94ab93857ebbf8b Mon Sep 17 00:00:00 2001 From: Benny Joo Date: Fri, 17 Jan 2025 06:46:59 -0500 Subject: [PATCH] chore: migrate `/auth/new` (#18732) * move out of /future dir * remove legacy pages --- .env.example | 1 - apps/web/abTest/middlewareFactory.ts | 1 - apps/web/app/{future => }/auth/new/page.tsx | 0 apps/web/pages/auth/new.tsx | 6 ------ apps/web/scripts/vercel-app-router-deploy.sh | 1 - turbo.json | 1 - 6 files changed, 10 deletions(-) rename apps/web/app/{future => }/auth/new/page.tsx (100%) delete mode 100644 apps/web/pages/auth/new.tsx diff --git a/.env.example b/.env.example index f08fe97cb5..3a67898313 100644 --- a/.env.example +++ b/.env.example @@ -367,7 +367,6 @@ APP_ROUTER_TEAM_ENABLED=0 APP_ROUTER_AUTH_FORGOT_PASSWORD_ENABLED=0 APP_ROUTER_AUTH_LOGIN_ENABLED=0 APP_ROUTER_AUTH_LOGOUT_ENABLED=0 -APP_ROUTER_AUTH_NEW_ENABLED=0 APP_ROUTER_AUTH_SAML_ENABLED=0 APP_ROUTER_AUTH_PLATFORM_ENABLED=0 APP_ROUTER_AUTH_OAUTH2_ENABLED=0 diff --git a/apps/web/abTest/middlewareFactory.ts b/apps/web/abTest/middlewareFactory.ts index d90c02dc31..2c0d74bc86 100644 --- a/apps/web/abTest/middlewareFactory.ts +++ b/apps/web/abTest/middlewareFactory.ts @@ -13,7 +13,6 @@ const ROUTES: [URLPattern, boolean][] = [ ["/auth/forgot-password/:path*", process.env.APP_ROUTER_AUTH_FORGOT_PASSWORD_ENABLED === "1"] as const, ["/auth/login", process.env.APP_ROUTER_AUTH_LOGIN_ENABLED === "1"] as const, ["/auth/logout", process.env.APP_ROUTER_AUTH_LOGOUT_ENABLED === "1"] as const, - ["/auth/new", process.env.APP_ROUTER_AUTH_NEW_ENABLED === "1"] as const, ["/auth/saml-idp", process.env.APP_ROUTER_AUTH_SAML_ENABLED === "1"] as const, ["/auth/platform/:path*", process.env.APP_ROUTER_AUTH_PLATFORM_ENABLED === "1"] as const, ["/auth/oauth2/:path*", process.env.APP_ROUTER_AUTH_OAUTH2_ENABLED === "1"] as const, diff --git a/apps/web/app/future/auth/new/page.tsx b/apps/web/app/auth/new/page.tsx similarity index 100% rename from apps/web/app/future/auth/new/page.tsx rename to apps/web/app/auth/new/page.tsx diff --git a/apps/web/pages/auth/new.tsx b/apps/web/pages/auth/new.tsx deleted file mode 100644 index ea4eb23669..0000000000 --- a/apps/web/pages/auth/new.tsx +++ /dev/null @@ -1,6 +0,0 @@ -export default function NewUserPage() { - if (typeof window !== "undefined") { - window.location.assign(process.env.NEXT_PUBLIC_WEBAPP_URL || "https://app.cal.com"); - } - return null; -} diff --git a/apps/web/scripts/vercel-app-router-deploy.sh b/apps/web/scripts/vercel-app-router-deploy.sh index b6e907e4f8..6600bf0780 100755 --- a/apps/web/scripts/vercel-app-router-deploy.sh +++ b/apps/web/scripts/vercel-app-router-deploy.sh @@ -14,7 +14,6 @@ checkRoute "$APP_ROUTER_APPS_CATEGORIES_CATEGORY_ENABLED" app/future/apps/catego checkRoute "$APP_ROUTER_AUTH_FORGOT_PASSWORD_ENABLED" app/future/auth/forgot-password checkRoute "$APP_ROUTER_AUTH_LOGIN_ENABLED" app/future/auth/login checkRoute "$APP_ROUTER_AUTH_LOGOUT_ENABLED" app/future/auth/logout -checkRoute "$APP_ROUTER_AUTH_NEW_ENABLED" app/future/auth/new checkRoute "$APP_ROUTER_AUTH_SAML_ENABLED" app/future/auth/saml-idp checkRoute "$APP_ROUTER_AUTH_PLATFORM_ENABLED" app/future/auth/platform checkRoute "$APP_ROUTER_AUTH_OAUTH2_ENABLED" app/future/auth/oauth2 diff --git a/turbo.json b/turbo.json index 6cfdff17d4..ee906ed56d 100644 --- a/turbo.json +++ b/turbo.json @@ -246,7 +246,6 @@ "APP_ROUTER_AUTH_FORGOT_PASSWORD_ENABLED", "APP_ROUTER_AUTH_LOGIN_ENABLED", "APP_ROUTER_AUTH_LOGOUT_ENABLED", - "APP_ROUTER_AUTH_NEW_ENABLED", "APP_ROUTER_AUTH_SAML_ENABLED", "APP_ROUTER_AUTH_PLATFORM_ENABLED", "APP_ROUTER_AUTH_OAUTH2_ENABLED",