From 613bb616cd62c584a606919e6978688e7b87d81e Mon Sep 17 00:00:00 2001 From: Miguel de la Cruz Date: Thu, 11 Dec 2025 10:13:44 +0100 Subject: [PATCH] Avoid triggering unnecessary rerenders on the shared channels tooltip for users (#34336) (#34702) Co-authored-by: Miguel de la Cruz Co-authored-by: Mattermost Build --- webapp/channels/src/components/user_profile/user_profile.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/webapp/channels/src/components/user_profile/user_profile.tsx b/webapp/channels/src/components/user_profile/user_profile.tsx index f501c3712c..a5dfb5dc20 100644 --- a/webapp/channels/src/components/user_profile/user_profile.tsx +++ b/webapp/channels/src/components/user_profile/user_profile.tsx @@ -36,10 +36,10 @@ export default function UserProfile({ }: Props) { // Fetch remote info when component mounts for remote users useEffect(() => { - if (user?.remote_id && (!remoteNames || remoteNames.length === 0)) { + if (user?.remote_id) { actions.fetchRemoteClusterInfo(user.remote_id); } - }, [user?.remote_id, remoteNames, actions]); + }, [user?.remote_id]); let name: ReactNode; if (user && displayUsername) { name = `@${(getUsername(user))}`;