final changes to sidebars

This commit is contained in:
Vladyslav Matsiiako
2023-07-11 00:04:14 -07:00
parent bdf4ebd1bc
commit 46dc357651
12 changed files with 18 additions and 386 deletions
+3 -3
View File
@@ -155,9 +155,9 @@ export const AppLayout = ({ children }: LayoutProps) => {
}
if (currentOrg && (
(workspaces?.length === 0 && !router.asPath.includes("org") && !router.asPath.includes("personal") && !router.asPath.includes("integration"))
(workspaces?.length === 0 && router.asPath.includes("project"))
|| router.asPath.includes("/project/undefined")
|| !orgs?.includes(router.query.id)
|| (!orgs?.includes(router.query.id) && !router.asPath.includes("project") && !router.asPath.includes("integration"))
)) {
router.push(`/org/${currentOrg?._id}/overview`);
}
@@ -186,7 +186,7 @@ export const AppLayout = ({ children }: LayoutProps) => {
};
putUserInOrg();
onboardingCheck({});
}, [currentOrg]);
}, [router.query.id]);
const onCreateProject = async ({ name, addMembers }: TAddProjectFormData) => {
// type check