Compare commits

...

10 Commits

Author SHA1 Message Date
Ajay Ramachandran
ddf3f7c6ff Increase version number 2021-05-16 17:32:58 -04:00
Ajay Ramachandran
fbcff7f4c4 Change video info fetch error message 2021-05-16 17:31:58 -04:00
Ajay Ramachandran
257098fd96 Fix description of error for force channel check 2021-05-13 12:20:39 -04:00
Ajay Ramachandran
0403393124 Increase version number 2021-05-12 17:01:54 -04:00
Ajay Ramachandran
11144fa77b Only ask for permission once 2021-05-12 17:00:31 -04:00
Ajay Ramachandran
dc5ecaded4 Merge pull request #737 from ajayyy/dependabot/npm_and_yarn/hosted-git-info-2.8.9
Bump hosted-git-info from 2.8.5 to 2.8.9
2021-05-10 20:12:48 -04:00
Ajay Ramachandran
60ae3111c2 Merge pull request #739 from ajayyy/dependabot/npm_and_yarn/lodash-4.17.21
Bump lodash from 4.17.19 to 4.17.21
2021-05-10 20:12:28 -04:00
Ajay Ramachandran
9f0f306439 Fix string 2021-05-10 18:06:59 -04:00
dependabot[bot]
8b7436320f Bump lodash from 4.17.19 to 4.17.21
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.19 to 4.17.21.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](https://github.com/lodash/lodash/compare/4.17.19...4.17.21)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-10 20:24:09 +00:00
dependabot[bot]
7498c6cf1b Bump hosted-git-info from 2.8.5 to 2.8.9
Bumps [hosted-git-info](https://github.com/npm/hosted-git-info) from 2.8.5 to 2.8.9.
- [Release notes](https://github.com/npm/hosted-git-info/releases)
- [Changelog](https://github.com/npm/hosted-git-info/blob/v2.8.9/CHANGELOG.md)
- [Commits](https://github.com/npm/hosted-git-info/compare/v2.8.5...v2.8.9)

Signed-off-by: dependabot[bot] <support@github.com>
2021-05-10 20:21:58 +00:00
6 changed files with 17 additions and 13 deletions

View File

@@ -1,7 +1,7 @@
{
"name": "__MSG_fullName__",
"short_name": "SponsorBlock",
"version": "2.0.14",
"version": "2.0.14.2",
"default_locale": "en",
"description": "__MSG_Description__",
"content_scripts": [{

12
package-lock.json generated
View File

@@ -7984,9 +7984,9 @@
}
},
"hosted-git-info": {
"version": "2.8.5",
"resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.5.tgz",
"integrity": "sha512-kssjab8CvdXfcXMXVcvsXum4Hwdq9XGtRD3TteMEvEbq0LXyiNQr6AprqKqfeaDXze7SxWvRxdpwE6ku7ikLkg=="
"version": "2.8.9",
"resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz",
"integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw=="
},
"html-encoding-sniffer": {
"version": "2.0.1",
@@ -11692,9 +11692,9 @@
}
},
"lodash": {
"version": "4.17.19",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz",
"integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ=="
"version": "4.17.21",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg=="
},
"lodash.defaults": {
"version": "4.2.0",

View File

@@ -591,8 +591,8 @@
"channelDataNotFound": {
"message": "Channel ID not loaded yet."
},
"adblockerIssue": {
"message": "It seems that something is blocking SponsorBlock's ability to get video data. This is probably your ad blocker. Please check https://github.com/ajayyy/SponsorBlock/wiki/Fix-Ad-Blocker-Blocking-SponsorBlock's-Requests"
"videoInfoFetchFailed": {
"message": "It seems that something is blocking SponsorBlock's ability to get video data. Please see https://github.com/ajayyy/SponsorBlock/issues/741 for more info."
},
"youtubePermissionRequest": {
"message": "It seems that SponsorBlock is unable to reach the YouTube API. To fix this, accept the permission prompt that will appear next, wait a few seconds, and then reload the page."
@@ -601,7 +601,7 @@
"message": "Accept permission"
},
"permissionRequestSuccess": {
"message": "Permission success succeeded!"
"message": "Permission request succeeded!"
},
"permissionRequestFailed": {
"message": "Permission request failed, did you click deny?"
@@ -610,7 +610,7 @@
"message": "If you are unable to resolve this, then disable the setting 'Ignore unlisted/private videos', as SponsorBlock is unable to retrieve the visibility information for this video"
},
"adblockerIssueWhitelist": {
"message": "If you are unable to resolve this, then disable the setting 'Force Channel Check Before Skipping', as SponsorBlock is unable to retrieve the visibility information for this video"
"message": "If you are unable to resolve this, then disable the setting 'Force Channel Check Before Skipping', as SponsorBlock is unable to retrieve the channel information for this video"
},
"itCouldBeAdblockerIssue": {
"message": "If this keeps occuring, it could be caused by your ad blocker. Please check https://github.com/ajayyy/SponsorBlock/wiki/Fix-Ad-Blocker-Blocking-SponsorBlock's-Requests"

View File

@@ -36,6 +36,7 @@ interface SBConfig {
testingServer: boolean,
hashPrefix: boolean,
refetchWhenNotFound: boolean,
ytInfoPermissionGranted: boolean,
// What categories should be skipped
categorySelections: CategorySelection[],
@@ -169,6 +170,7 @@ const Config: SBObject = {
testingServer: false,
hashPrefix: true,
refetchWhenNotFound: true,
ytInfoPermissionGranted: false,
categorySelections: [{
name: "sponsor",

View File

@@ -733,7 +733,7 @@ async function getVideoInfo(): Promise<void> {
async function videoInfoFetchFailed(errorMessage: string): Promise<void> {
console.log("failed\t" + errorMessage)
if (utils.isFirefox()) {
if (utils.isFirefox() && !Config.config.ytInfoPermissionGranted) {
// Attempt to ask permission for youtube.com domain
alert(chrome.i18n.getMessage("youtubePermissionRequest"));
@@ -742,7 +742,7 @@ async function videoInfoFetchFailed(errorMessage: string): Promise<void> {
url: "permissions/index.html#youtube.com"
});
} else {
alert(chrome.i18n.getMessage("adblockerIssue") + "\n\n" + chrome.i18n.getMessage(errorMessage));
alert(chrome.i18n.getMessage("videoInfoFetchFailed") + "\n\n" + chrome.i18n.getMessage(errorMessage));
}
}

View File

@@ -22,6 +22,8 @@ async function init() {
if (granted) {
alert(chrome.i18n.getMessage("permissionRequestSuccess"));
Config.config.ytInfoPermissionGranted = true;
chrome.tabs.getCurrent((tab) => {
chrome.tabs.remove(tab.id);
});