Merge branch 'fix-follow-relationship' into 'develop'

Fix follow notifications not having relationship

Closes #1446

See merge request soapbox-pub/soapbox!2578
This commit is contained in:
Alex Gleason 2023-06-28 14:56:09 +00:00
commit 0c83f840fb
2 changed files with 6 additions and 2 deletions

View file

@ -5,10 +5,11 @@ import Account, { IAccount } from 'soapbox/components/account';
interface IAccountContainer extends Omit<IAccount, 'account'> {
id: string
withRelationship?: boolean
}
const AccountContainer: React.FC<IAccountContainer> = ({ id, ...props }) => {
const { account } = useAccount(id);
const AccountContainer: React.FC<IAccountContainer> = ({ id, withRelationship, ...props }) => {
const { account } = useAccount(id, { withRelationship });
return (
<Account account={account!} {...props} />

View file

@ -304,6 +304,7 @@ const Notification: React.FC<INotificaton> = (props) => {
id={account.id}
hidden={hidden}
avatarSize={avatarSize}
withRelationship
/>
) : null;
case 'follow_request':
@ -313,6 +314,7 @@ const Notification: React.FC<INotificaton> = (props) => {
hidden={hidden}
avatarSize={avatarSize}
actionType='follow_request'
withRelationship
/>
) : null;
case 'move':
@ -321,6 +323,7 @@ const Notification: React.FC<INotificaton> = (props) => {
id={notification.target.id}
hidden={hidden}
avatarSize={avatarSize}
withRelationship
/>
) : null;
case 'favourite':