Add underscore to youtube regex

paste-quickfix
Evan Tschuy 9 years ago committed by GitHub
parent 1d1a1e2818
commit d1921c49e2
  1. 2
      js/plugins.js

@ -206,7 +206,7 @@ plugins.factory('userPlugins', function() {
* See: https://developers.google.com/youtube/player_parameters * See: https://developers.google.com/youtube/player_parameters
*/ */
var youtubePlugin = new UrlPlugin('YouTube video', function(url) { var youtubePlugin = new UrlPlugin('YouTube video', function(url) {
var regex = /(?:youtube.com|youtu.be)\/(?:v\/|embed\/|watch(?:\?v=|\/))?([a-zA-Z0-9-]+)/i, var regex = /(?:youtube.com|youtu.be)\/(?:v\/|embed\/|watch(?:\?v=|\/))?([a-zA-Z0-9_-]+)/i,
match = url.match(regex); match = url.match(regex);
if (match){ if (match){

Loading…
Cancel
Save