From 8f9edf9d5d6bc3ef66c4085a2621276cd08da7e6 Mon Sep 17 00:00:00 2001 From: Echo Date: Thu, 1 Oct 2026 15:16:58 +0000 Subject: [PATCH] Status redesign: Check for account ID when displaying link authors (#40808) --- .../mastodon/components/status/attachments.tsx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/app/javascript/mastodon/components/status/attachments.tsx b/app/javascript/mastodon/components/status/attachments.tsx index 841546da7c5..8c7db1b73fe 100644 --- a/app/javascript/mastodon/components/status/attachments.tsx +++ b/app/javascript/mastodon/components/status/attachments.tsx @@ -413,6 +413,10 @@ const LinkCard: React.FC<{ card: CardShape; status: ExpandedStatusShape }> = ({ rel: 'noopener', } as const; + const authors = card.authors + .map(({ accountId }) => accountId) + .filter((id): id is string => !!id); + return ( = ({ )} - {card.authors.length > 0 && ( + {authors.length > 0 && ( - {card.authors.map(({ accountId }) => ( + {authors.map((accountId) => ( ))}