From 5326cd2fdc19a3630270357c73aed01d3e859530 Mon Sep 17 00:00:00 2001 From: SySagar Date: Mon, 26 Feb 2024 18:17:00 +0530 Subject: [PATCH] fix: user profile --- src/app/profile/[profile].jsx | 4 ++-- src/app/team/components/AllTeams.jsx | 1 + src/app/team/components/MemberCard.jsx | 4 ++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/app/profile/[profile].jsx b/src/app/profile/[profile].jsx index 196333e..dd8470d 100644 --- a/src/app/profile/[profile].jsx +++ b/src/app/profile/[profile].jsx @@ -35,7 +35,7 @@ export default function UserProfile() { setUser({ username: res.data.username, name: res.data.name, - avatar: import.meta.env.VITE_BASE_URL + "/media/" + res.data.avatar, + avatar: res.data.avatar, graduationYear: res.data.graduation_year, linkedin_handle: res.data.linkedin_url, twitter_handle: res.data.twitter_username, @@ -50,7 +50,7 @@ export default function UserProfile() { ))} diff --git a/src/app/team/components/MemberCard.jsx b/src/app/team/components/MemberCard.jsx index 9f4319a..c680b21 100644 --- a/src/app/team/components/MemberCard.jsx +++ b/src/app/team/components/MemberCard.jsx @@ -12,9 +12,9 @@ import AndroidIcon from "@mui/icons-material/Android"; import SmartToyIcon from "@mui/icons-material/SmartToy"; import OpenInNewIcon from "@mui/icons-material/OpenInNew"; -export default function MemberCard({ memberImage, memberName }) { +export default function MemberCard({ memberImage, memberName, memberUsername }) { const profileRedirect = () => { - const newPageUrl = "/profile/" + memberName; + const newPageUrl = "/profile/" + memberUsername; window.open(newPageUrl, "_blank"); };