Skip to content

armgit / kaneo

Public Imported from GitHub
0

⚡ Project management that doesn't become the project. Boards, Gantt charts, and GitHub integration. Self-host it or use Kaneo Cloud.

refactor: remove workspace retrieval logic from dashboard route

Andrej Acevski257c1af1b473
diff --git a/apps/web/src/routes/dashboard.tsx b/apps/web/src/routes/dashboard.tsx
index d261e01ad..5263235ee 100644
--- a/apps/web/src/routes/dashboard.tsx
+++ b/apps/web/src/routes/dashboard.tsx
@@ -2,7 +2,6 @@ import { DemoAlert } from "@/components/demo-alert";
import PageTitle from "@/components/page-title";
import { SidebarProvider } from "@/components/ui/sidebar";
import { isDemoMode } from "@/constants/urls";
-import getWorkspaces from "@/fetchers/workspace/get-workspaces";
import useGetWorkspaces from "@/hooks/queries/workspace/use-get-workspaces";
import { useUserPreferencesStore } from "@/store/user-preferences";
import useWorkspaceStore from "@/store/workspace";
@@ -17,14 +16,6 @@ export const Route = createFileRoute("/dashboard")({
to: "/auth/sign-in",
});
}
-
- const workspaces = await getWorkspaces();
-
- if (workspaces.length === 0) {
- throw redirect({
- to: "/dashboard/workspace/create",
- });
- }
},
});