Merge branch 'master' of https://github.com/ajayyy/SponsorBlock into chapters

This commit is contained in:
Ajay
2022-05-17 14:44:54 -04:00
49 changed files with 8210 additions and 2232 deletions

View File

@@ -6,7 +6,6 @@ import { keybindEquals } from "./utils/configUtils";
interface SBConfig {
userID: string,
isVip: boolean,
lastIsVipUpdate: number,
/* Contains unsubmitted segments that the user has created. */
unsubmittedSegments: Record<string, SponsorTime[]>,
defaultCategory: Category,
@@ -125,7 +124,6 @@ const Config: SBObject = {
syncDefaults: {
userID: null,
isVip: false,
lastIsVipUpdate: 0,
unsubmittedSegments: {},
defaultCategory: "chooseACategory" as Category,
renderAsChapters: true,
@@ -489,6 +487,10 @@ function migrateOldSyncFormats(config: SBConfig) {
if (!config["supportInvidious"] && config["invidiousInstances"].length !== invidiousList.length) {
config["invidiousInstances"] = invidiousList;
}
if (config["lastIsVipUpdate"]) {
chrome.storage.sync.remove("lastIsVipUpdate");
}
}
async function setupConfig() {