Fix 'unknown' media attachment rendering in detailed view (#32713)

This commit is contained in:
Renato "Lond" Cerqueira 2024-10-31 10:37:31 +01:00 committed by Sunoru
parent 2636095368
commit d8f9ff25b6
Signed by: sunoru
GPG key ID: 442B84461FD0355A

View file

@ -152,7 +152,7 @@ export const DetailedStatus: React.FC<{
media = <PictureInPicturePlaceholder aspectRatio={attachmentAspectRatio} />;
} else if (status.get('media_attachments').size > 0) {
if (
['image', 'gifv'].includes(
['image', 'gifv', 'unknown'].includes(
status.getIn(['media_attachments', 0, 'type']) as string,
) ||
status.get('media_attachments').size > 1