Skip to content

Commit

Permalink
only use podcast type if its a beta container
Browse files Browse the repository at this point in the history
  • Loading branch information
abeddow91 committed Dec 17, 2024
1 parent 5a69638 commit 2d06d88
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion dotcom-rendering/src/components/Card/Card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ const getMedia = ({
mainMedia,
isPlayableMediaCard,
podcastImage,
isBetaContainer,
}: {
imageUrl?: string;
imageAltText?: string;
Expand All @@ -204,6 +205,7 @@ const getMedia = ({
mainMedia?: MainMedia;
isPlayableMediaCard?: boolean;
podcastImage?: PodcastSeriesImage;
isBetaContainer: boolean;
}) => {
if (mainMedia && mainMedia.type === 'Video' && isPlayableMediaCard) {
return {
Expand All @@ -214,7 +216,7 @@ const getMedia = ({
}
if (slideshowImages) return { type: 'slideshow', slideshowImages } as const;
if (avatarUrl) return { type: 'avatar', avatarUrl } as const;
if (podcastImage) {
if (podcastImage && isBetaContainer) {
return {
type: 'podcast',
podcastImage,
Expand Down Expand Up @@ -436,6 +438,7 @@ export const Card = ({
mainMedia,
isPlayableMediaCard,
podcastImage,
isBetaContainer,
});

// For opinion type cards with avatars (which aren't onwards content)
Expand Down

0 comments on commit 2d06d88

Please sign in to comment.