Fix changing autodownload settings

This commit is contained in:
Eduard Kuzmenko 2022-09-03 20:51:04 +02:00
parent 8a523a74e9
commit 905451c7bf
1 changed files with 2 additions and 1 deletions

View File

@ -61,7 +61,7 @@ export default class AppDataAndStorageTab extends SliderSuperTabEventable {
};
const openTab = (tabConstructor: SliderSuperTabEventableConstructable) => {
const tab = new tabConstructor(this.slider, true);
const tab = this.slider.createTab(tabConstructor);
tab.open();
this.listenerSetter.add(tab.eventListener)('destroy', () => {
@ -109,6 +109,7 @@ export default class AppDataAndStorageTab extends SliderSuperTabEventable {
const settings = rootScope.settings;
settings.autoDownloadNew = copy(STATE_INIT.settings.autoDownloadNew);
settings.autoDownload = copy(STATE_INIT.settings.autoDownload);
state.settings = settings;
this.managers.appStateManager.setByKey('settings', settings);
setSubtitles();