Skip to content

Commit

Permalink
Fix Recruiter Dashboard infinite loop
Browse files Browse the repository at this point in the history
  • Loading branch information
robines committed Sep 24, 2024
1 parent 742c4ac commit 2a35061
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@ export function RecruitmentRecruiterDashboardPage() {
const [applications, setApplications] = useState<RecruitmentApplicationDto[]>();
const [loading, setLoading] = useState(true);

// biome-ignore lint/correctness/useExhaustiveDependencies: navigate must not be in deplist
useEffect(() => {
if (recruitmentId) {
if (!recruitmentId) return;
getRecruitmentRecruiterDashboard(recruitmentId)
.then((resp) => {
setRecruitment(resp.data.recruitment);
Expand All @@ -38,8 +39,7 @@ export function RecruitmentRecruiterDashboardPage() {
navigate({ url: ROUTES.frontend.not_found });
}
});
}
}, [navigate, recruitmentId, t]);
}, [recruitmentId, t]);

if (!recruitmentId) {
navigate({ url: ROUTES.frontend.not_found });
Expand Down

0 comments on commit 2a35061

Please sign in to comment.