diff --git a/site/components/Paragraph.js b/site/components/Paragraph.js index 746af8c..6c2d7b2 100644 --- a/site/components/Paragraph.js +++ b/site/components/Paragraph.js @@ -1,6 +1,6 @@ import LiteYouTubeEmbed from "react-lite-youtube-embed"; import TwitterEmbed from "./TwitterEmbed"; -import { YOUTUBE_REGEX, TWITTER_REGEX, YOUTUBE_ID_REGEX } from "../lib/constants"; +import { TWITTER_REGEX, YOUTUBE_ID_REGEX } from "../lib/constants"; export const Paragraph = (props) => { if ( @@ -10,7 +10,7 @@ export const Paragraph = (props) => { ) { const href = props.children.props.href - if (YOUTUBE_REGEX.test(href)) { + if (YOUTUBE_ID_REGEX.test(href)) { const youtubeId = href.match(YOUTUBE_ID_REGEX)[1]; let startTime = href.match(/t=[0-9]*/) if (startTime) startTime = startTime[0].split("=").pop()