Skip to content

Commit

Permalink
v2.5.2: more resilient YouTube Regex
Browse files Browse the repository at this point in the history
  • Loading branch information
soufianesakhi committed Oct 24, 2021
1 parent aafa6e5 commit 2e0ca4e
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion playlist-editor/src/services/video-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ window.videoIdCount = 100;

// https://regex101.com/r/mPyKKP/1/
window.youtubeRegexPattern =
/(?:https?:\/\/)?(?:www\.)?youtu(?:\.be\/|be.com\/\S*(?:watch|embed)(?:(?:(?=\/[^&\s\?]+(?!\S))\/)|(?:\S*v=|v\/)))([^&\s\?]+)/.source;
/(?:https?:\/\/)?(?:www\.)?youtu(?:\.be\/|be.com\/\S*(?:watch|embed)(?:(?:(?=\/[^&\s\?\."'<]{11,}(?!\S))\/)|(?:\S*v=|v\/)))([^&\s\?\."'<]{11,})/.source;

class VideoService {
YOUTUBE_URL_PREFIX = "https://www.youtube.com/watch?v=";
Expand Down
2 changes: 1 addition & 1 deletion src/editor/bundle.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/editor/video-service.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "YouTube Playlist Helper",
"description": "Generate YouTube playlists from various sources (links lists, bookmarks, ...)",
"version": "2.5.1",
"version": "2.5.2",
"manifest_version": 2,
"icons": {
"48": "icons/icon_48.png",
Expand Down

0 comments on commit 2e0ca4e

Please sign in to comment.