diff --git a/app/javascript/flavours/glitch/features/account_featured/components/empty_message.tsx b/app/javascript/flavours/glitch/features/account_featured/components/empty_message.tsx index 8e7d0703c8..fa910b923e 100644 --- a/app/javascript/flavours/glitch/features/account_featured/components/empty_message.tsx +++ b/app/javascript/flavours/glitch/features/account_featured/components/empty_message.tsx @@ -1,6 +1,9 @@ import { FormattedMessage } from 'react-intl'; +import { useParams } from 'react-router'; + import { LimitedAccountHint } from 'flavours/glitch/features/account_timeline/components/limited_account_hint'; +import { me } from 'flavours/glitch/initial_state'; interface EmptyMessageProps { suspended: boolean; @@ -15,13 +18,21 @@ export const EmptyMessage: React.FC = ({ hidden, blockedBy, }) => { + const { acct } = useParams<{ acct?: string }>(); if (!accountId) { return null; } let message: React.ReactNode = null; - if (suspended) { + if (me === accountId) { + message = ( + + ); + } else if (suspended) { message = ( = ({ defaultMessage='Profile unavailable' /> ); + } else if (acct) { + message = ( + + ); } else { message = ( ); }