diff --git a/src/renderer/src/pages/user/user-content.tsx b/src/renderer/src/pages/user/user-content.tsx index 2946523d..b16c49bb 100644 --- a/src/renderer/src/pages/user/user-content.tsx +++ b/src/renderer/src/pages/user/user-content.tsx @@ -115,7 +115,7 @@ export function UserContent({ useEffect(() => { if (isMe) fetchFriendRequests(); - }, [isMe]); + }, [isMe, fetchFriendRequests]); useEffect(() => { if (isMe && profileBackground) { @@ -129,7 +129,7 @@ export function UserContent({ } ); } - }, [profileBackground, isMe]); + }, [profileBackground, isMe, userProfile.profileImageUrl]); const handleFriendAction = (userId: string, action: FriendAction) => { try { diff --git a/src/renderer/src/pages/user/user.tsx b/src/renderer/src/pages/user/user.tsx index 4c45f789..565d412a 100644 --- a/src/renderer/src/pages/user/user.tsx +++ b/src/renderer/src/pages/user/user.tsx @@ -31,7 +31,7 @@ export const User = () => { navigate(-1); } }); - }, [dispatch, userId, t]); + }, [dispatch, navigate, showErrorToast, userId, t]); useEffect(() => { getUserProfile();