diff --git a/website/src/components/featurePodcast.js b/website/src/components/featurePodcast.js index f9bcba6..18cc0a3 100644 --- a/website/src/components/featurePodcast.js +++ b/website/src/components/featurePodcast.js @@ -7,33 +7,26 @@ import SpotifyCompact from '../components/spotifyCompact'; import VideoPlayer from '../components/videoPlayer'; export default function FeaturePodcast(props) { - - var defined = function(property){ + var defined = function(property) { return typeof property !== 'undefined'; }; - if(!props.featured){ - return; + if (!props.featured) { + return null; } return (

{props.title}

- {props.type === "soundcloud" && - - } - {props.type === "spotify" && - - } - {props.type === "video" && - - } - {defined(props.podcastUrl) && props.podcastUrl !== '' && + {props.type === "soundcloud" && } + {props.type === "spotify" && } + {props.type === "video" && } + {props.type !== "video" && defined(props.podcastUrl) && props.podcastUrl !== '' && ( {props.podcast} - } - {defined(props.description) && props.description !== '' && + )} + {defined(props.description) && props.description !== '' && (

{props.description}

- } + )}
); };