From ac6ae23c8e72b0b79998c32b0e91873ed2bb0e59 Mon Sep 17 00:00:00 2001 From: lfbrock Date: Thu, 29 Sep 2016 06:56:50 -0700 Subject: Add 'm.youtube.com/...' to be recognized as a YouTube link in the embedded post content. (#4114) --- webapp/components/youtube_video.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/webapp/components/youtube_video.jsx b/webapp/components/youtube_video.jsx index 0012b1e98..d551364f3 100644 --- a/webapp/components/youtube_video.jsx +++ b/webapp/components/youtube_video.jsx @@ -5,7 +5,7 @@ import ChannelStore from 'stores/channel_store.jsx'; import WebClient from 'client/web_client.jsx'; import * as Utils from 'utils/utils.jsx'; -const ytRegex = /(?:http|https):\/\/(?:www\.)?(?:(?:youtube\.com\/(?:(?:v\/)|(\/u\/\w\/)|(?:(?:watch|embed\/watch)(?:\/|.*v=))|(?:embed\/)|(?:user\/[^\/]+\/u\/[0-9]\/)))|(?:youtu\.be\/))([^#&\?]*)/; +const ytRegex = /(?:http|https):\/\/(?:www\.|m\.)?(?:(?:youtube\.com\/(?:(?:v\/)|(?:(?:watch|embed\/watch)(?:\/|.*v=))|(?:embed\/)|(?:user\/[^\/]+\/u\/[0-9]\/)))|(?:youtu\.be\/))([^#&\?]*)/; import React from 'react'; -- cgit v1.2.3-1-g7c22