mirror of
https://github.com/Portabase/portabase.git
synced 2026-07-14 11:16:13 +02:00
Preparing the repository
This commit is contained in:
@@ -1,11 +1,14 @@
|
||||
import {redirect} from "next/navigation";
|
||||
import {currentUser} from "@/auth/current-user";
|
||||
import {getCurrentOrganizationSlug} from "@/features/dashboard/organization-cookie";
|
||||
|
||||
|
||||
export default async function Index() {
|
||||
const user = await currentUser()
|
||||
if (user) {
|
||||
redirect("/dashboard")
|
||||
const currentOrganizationSlug = await getCurrentOrganizationSlug()
|
||||
|
||||
redirect(`/dashboard/${currentOrganizationSlug}/projects`)
|
||||
}
|
||||
redirect("/login")
|
||||
//Do not delete
|
||||
|
||||
Reference in New Issue
Block a user