From 15882904ebc2a7941ee7c942735271ae173d9366 Mon Sep 17 00:00:00 2001 From: James Grugett Date: Fri, 10 Jun 2022 12:55:55 -0500 Subject: [PATCH] Disallow following yourself via market page --- web/components/follow-button.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/web/components/follow-button.tsx b/web/components/follow-button.tsx index f2dd0d82..f2a67b9b 100644 --- a/web/components/follow-button.tsx +++ b/web/components/follow-button.tsx @@ -57,7 +57,7 @@ export function UserFollowButton(props: { userId: string; small?: boolean }) { const following = useFollows(currentUser?.id) const isFollowing = following?.includes(userId) - if (!currentUser) return null + if (!currentUser || currentUser.id === userId) return null return (