From db46d0438ff988c6bb58f2fd348c60659d7cbcc4 Mon Sep 17 00:00:00 2001 From: Ajay Ramachandran Date: Sat, 3 Aug 2019 22:12:20 -0400 Subject: [PATCH] Added whitelist support to the old YouTube theme. --- content.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/content.js b/content.js index 395e8838..98469dc8 100644 --- a/content.js +++ b/content.js @@ -307,6 +307,14 @@ function getChannelID() { } } + if (channelContainers.length == 0) { + //old YouTube theme + channelContainers = document.getElementsByClassName("yt-user-info"); + if (channelContainers.length != 0) { + channelURLContainer = channelContainers[0].firstElementChild; + } + } + if (channelURLContainer == null) { //try later setTimeout(getChannelID, 100);