chore: redirection to profile after workpace delete/leave (#2937)

This commit is contained in:
Lakhan Baheti
2023-11-29 16:52:54 +05:30
committed by sriram veeraghanta
parent a477161fca
commit c2b90df498
2 changed files with 3 additions and 10 deletions

View File

@@ -40,14 +40,8 @@ const useUserAuth = (routeAuth: "sign-in" | "onboarding" | "admin" | null = "adm
router.push(`/${userWorkspaces[0].slug}`);
return;
} else {
const invitations = await workspaceService.userWorkspaceInvitations();
if (invitations.length > 0) {
router.push(`/invitations`);
return;
} else {
router.push(`/create-workspace`);
return;
}
router.push(`/profile`);
return;
}
});
};