From 95ad3cf09bb0ac7b85878a3c73ce8bd4b9a24526 Mon Sep 17 00:00:00 2001 From: MichaelOultram Date: Sun, 16 Aug 2015 01:28:22 +0100 Subject: [PATCH] Reverted youtube patterns --- service_youtube.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/service_youtube.go b/service_youtube.go index cc5a536..06c9543 100644 --- a/service_youtube.go +++ b/service_youtube.go @@ -25,9 +25,11 @@ import ( // Regular expressions for youtube urls var youtubePlaylistPattern = `https?:\/\/www\.youtube\.com\/playlist\?list=([\w-]+)` var youtubeVideoPatterns = []string{ - `https?:\/\/(www\.)?youtube\.com\/watch\?v=([\w-]+)(\&t=\d*m?\d*s?)?`, - `https?:\/\/(www\.)?youtube\.com\/v\/([\w-]+)(\?t=\d*m?\d*s?)?`, + `https?:\/\/www\.youtube\.com\/watch\?v=([\w-]+)(\&t=\d*m?\d*s?)?`, + `https?:\/\/youtube\.com\/watch\?v=([\w-]+)(\&t=\d*m?\d*s?)?`, `https?:\/\/youtu.be\/([\w-]+)(\?t=\d*m?\d*s?)?`, + `https?:\/\/youtube.com\/v\/([\w-]+)(\?t=\d*m?\d*s?)?`, + `https?:\/\/www.youtube.com\/v\/([\w-]+)(\?t=\d*m?\d*s?)?`, } // ------