diff options
Diffstat (limited to 'src/config.ts')
-rw-r--r-- | src/config.ts | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/config.ts b/src/config.ts index 12b8ab27..7baf2999 100644 --- a/src/config.ts +++ b/src/config.ts @@ -38,6 +38,7 @@ interface SBConfig { ytInfoPermissionGranted: boolean, allowExpirements: boolean, autoHideInfoButton: boolean, + autoSkipOnMusicVideos: boolean, // What categories should be skipped categorySelections: CategorySelection[], @@ -179,6 +180,7 @@ const Config: SBObject = { ytInfoPermissionGranted: false, allowExpirements: true, autoHideInfoButton: true, + autoSkipOnMusicVideos: false, categorySelections: [{ name: "sponsor" as Category, @@ -365,6 +367,18 @@ function migrateOldFormats(config: SBConfig) { chrome.storage.sync.remove("askAboutUnlistedVideos"); } + if (!config["autoSkipOnMusicVideosUpdate"]) { + config["autoSkipOnMusicVideosUpdate"] = true; + for (const selection of config.categorySelections) { + if (selection.name === "music_offtopic" + && selection.option === CategorySkipOption.AutoSkip) { + + config.autoSkipOnMusicVideos = true; + break; + } + } + } + // Adding preview category if (!config["previewCategoryUpdate"]) { config["previewCategoryUpdate"] = true; |