1
0
mirror of https://github.com/aureliendavid/rsspreview.git synced 2025-08-22 11:18:37 +00:00

youtube: handle user/<username> urls (#55)

This commit is contained in:
Aurelien David 2020-07-08 10:51:11 +02:00
parent ecc7288d44
commit 884a7c3697

View File

@ -383,7 +383,7 @@
// It also supports named channels of the form /c/MyChannelName
// Match on both of these to autodetect channel feeds on either URL
let idPattern = /channel\/(?<channelId>[a-zA-Z0-9_-]+)/;
let namePattern = /c\/[a-zA-Z0-9_-]+/;
let namePattern = /(?:c|user)\/[a-zA-Z0-9_-]+/;
let urlPattern = new RegExp(`${idPattern.source}|${namePattern.source}`);
if (document.URL.match(urlPattern)) {
let feeds = {};