From f286868cbe0165b14df92d7342e05e47871bfc9e Mon Sep 17 00:00:00 2001 From: James Ketrenos Date: Mon, 2 Jun 2025 17:36:47 -0700 Subject: [PATCH] Image profile update works --- frontend/src/pages/FindCandidatePage.tsx | 2 +- frontend/src/pages/candidate/Profile.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/pages/FindCandidatePage.tsx b/frontend/src/pages/FindCandidatePage.tsx index d258b84..6072baf 100644 --- a/frontend/src/pages/FindCandidatePage.tsx +++ b/frontend/src/pages/FindCandidatePage.tsx @@ -61,7 +61,7 @@ const CandidateListingPage = (props: BackstoryPageProps) => { onClick={() => { setSelectedCandidate(u); navigate("/chat"); }} sx={{ cursor: "pointer" }}> {selectedCandidate?.id === u.id && - + } {selectedCandidate?.id !== u.id && diff --git a/frontend/src/pages/candidate/Profile.tsx b/frontend/src/pages/candidate/Profile.tsx index d54367a..af4783f 100644 --- a/frontend/src/pages/candidate/Profile.tsx +++ b/frontend/src/pages/candidate/Profile.tsx @@ -207,7 +207,7 @@ const CandidateProfilePage: React.FC = (props: BackstoryPage const handleImageUpload = async (e: React.ChangeEvent) => { if (e.target.files && e.target.files[0]) { if (await apiClient.uploadCandidateProfile(e.target.files[0])) { - candidate.profileImage = e.target.files[0].name; + candidate.profileImage = 'profile.' + e.target.files[0].name.replace(/^.*\./, ''); updateUserData(candidate); } }