diff --git a/apps/web/src/components/NewWorkspaceForm.tsx b/apps/web/src/components/NewWorkspaceForm.tsx index dd2545c7..3d0ccd5c 100644 --- a/apps/web/src/components/NewWorkspaceForm.tsx +++ b/apps/web/src/components/NewWorkspaceForm.tsx @@ -42,7 +42,7 @@ type FormValues = z.infer; export function NewWorkspaceForm() { const { closeModal } = useModal(); const { showPopup } = usePopup(); - const { switchWorkspace } = useWorkspace(); + const { switchWorkspace, availableWorkspaces } = useWorkspace(); const { register, handleSubmit, @@ -60,6 +60,8 @@ export function NewWorkspaceForm() { }); const utils = api.useUtils(); + const hasAvailableWorkspaces = availableWorkspaces.length > 0; + const isCloudEnv = env("NEXT_PUBLIC_KAN_ENV") === "cloud"; const slug = watch("slug"); @@ -209,7 +211,10 @@ export function NewWorkspaceForm() {