mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2024-09-20 04:53:43 +02:00
Made getChannelID only get called if there is a valid YouTube page.
This commit is contained in:
parent
f310c53f88
commit
7deea5d648
1 changed files with 3 additions and 3 deletions
|
@ -240,12 +240,12 @@ function videoIDChange(id) {
|
||||||
|
|
||||||
resetValues();
|
resetValues();
|
||||||
|
|
||||||
let channelIDPromise = wait(getChannelID);
|
|
||||||
channelIDPromise.then(() => channelIDPromise.isFulfilled = true).catch(() => channelIDPromise.isRejected = true)
|
|
||||||
|
|
||||||
//id is not valid
|
//id is not valid
|
||||||
if (!id) return;
|
if (!id) return;
|
||||||
|
|
||||||
|
let channelIDPromise = wait(getChannelID);
|
||||||
|
channelIDPromise.then(() => channelIDPromise.isFulfilled = true).catch(() => channelIDPromise.isRejected = true);
|
||||||
|
|
||||||
//setup the preview bar
|
//setup the preview bar
|
||||||
if (previewBar == null) {
|
if (previewBar == null) {
|
||||||
//create it
|
//create it
|
||||||
|
|
Loading…
Reference in a new issue