From 4bdddb17104c2ba9cf54c2a08241916b00f0071a Mon Sep 17 00:00:00 2001 From: SleeplessOne1917 Date: Sat, 17 Jun 2023 12:00:13 +0000 Subject: [PATCH] Add default profile picture for users who do not set one (#1339) --- src/shared/components/person/person-details.tsx | 10 ---------- src/shared/components/person/person-listing.tsx | 10 +++++++--- 2 files changed, 7 insertions(+), 13 deletions(-) diff --git a/src/shared/components/person/person-details.tsx b/src/shared/components/person/person-details.tsx index 07f5431..d1f3196 100644 --- a/src/shared/components/person/person-details.tsx +++ b/src/shared/components/person/person-details.tsx @@ -107,16 +107,6 @@ export class PersonDetails extends Component { setupTippy(); } - // TODO wut? - // componentDidUpdate(lastProps: UserDetailsProps) { - // for (const key of Object.keys(lastProps)) { - // if (lastProps[key] !== this.props[key]) { - // this.fetchUserData(); - // break; - // } - // } - // } - render() { return (
diff --git a/src/shared/components/person/person-listing.tsx b/src/shared/components/person/person-listing.tsx index 1f0466b..fe8b841 100644 --- a/src/shared/components/person/person-listing.tsx +++ b/src/shared/components/person/person-listing.tsx @@ -73,10 +73,14 @@ export class PersonListing extends Component { const avatar = this.props.person.avatar; return ( <> - {avatar && - !this.props.hideAvatar && + {!this.props.hideAvatar && !this.props.person.banned && - showAvatars() && } + showAvatars() && ( + + )} {displayName} ); -- 2.44.1