From 1e2593894c3183aae71bf90784e03bef91464d21 Mon Sep 17 00:00:00 2001 From: James Grugett Date: Sun, 4 Sep 2022 00:03:04 -0500 Subject: [PATCH] Allow admins to see bets page --- web/components/user-page.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/web/components/user-page.tsx b/web/components/user-page.tsx index 1ddee3d0..3d6e4386 100644 --- a/web/components/user-page.tsx +++ b/web/components/user-page.tsx @@ -39,6 +39,7 @@ import { PortfolioValueSection } from './portfolio/portfolio-value-section' import { filterDefined } from 'common/util/array' import { useUserBets } from 'web/hooks/use-user-bets' import { ReferralsButton } from 'web/components/referrals-button' +import { ENV_CONFIG } from 'common/envs/constants' export function UserLink(props: { name: string @@ -288,7 +289,11 @@ export function UserPage(props: { user: User; currentUser?: User }) { ), }, - ...(isCurrentUser + ...(isCurrentUser || + [ + ...(ENV_CONFIG.whitelistCreators ?? []), + 'JamesGrugett', + ].includes(currentUser?.username ?? '') ? [ { title: 'Bets',