mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2024-11-10 09:07:45 +01:00
Fixed regex to support Firefox.
This commit is contained in:
parent
2f2c1ad49b
commit
2454cd9a39
1 changed files with 1 additions and 1 deletions
|
@ -446,7 +446,7 @@ function sponsorsLookup(id: string, channelIDPromise?) {
|
|||
//use the invidious api to get the time published
|
||||
sendRequestToCustomServer('GET', "https://www.youtube.com/get_video_info?video_id=" + id, function(xmlhttp, error) {
|
||||
if (xmlhttp.readyState == 4 && xmlhttp.status == 200) {
|
||||
let decodedData = decodeURIComponent(xmlhttp.responseText).match(/(?<=player_response=)[^&]*/)[0];
|
||||
let decodedData = decodeURIComponent(xmlhttp.responseText).match(/player_response=([^&]*)/)[1];
|
||||
|
||||
if (decodedData === undefined) {
|
||||
console.error("[SB] Failed at getting video upload date info from YouTube.");
|
||||
|
|
Loading…
Reference in a new issue