Enable chapter by default

This commit is contained in:
Ajay
2023-03-18 21:30:33 -04:00
parent 2f68a66f13
commit f00b3abbe4

View File

@@ -145,6 +145,19 @@ class ConfigClass extends ProtoConfig<SBConfig, SBStorage> {
}
function migrateOldSyncFormats(config: SBConfig) {
if (!config["chapterCategoryAdded"]) {
config["chapterCategoryAdded"] = true;
if (!config.categorySelections.some((s) => s.name === "chapter")) {
config.categorySelections.push({
name: "chapter" as Category,
option: CategorySkipOption.ShowOverlay
});
config.categorySelections = config.categorySelections;
}
}
if (config["segmentTimes"]) {
const unsubmittedSegments = {};
for (const item of config["segmentTimes"]) {
@@ -325,6 +338,9 @@ const syncDefaults = {
}, {
name: "exclusive_access" as Category,
option: CategorySkipOption.ShowOverlay
}, {
name: "chapter" as Category,
option: CategorySkipOption.ShowOverlay
}],
payments: {