Settings are now more centralized in the frontend

This commit is contained in:
Adam Verga
2020-04-29 20:15:15 -04:00
parent ff51a49d1b
commit a48e122763
5 changed files with 73 additions and 87 deletions

View File

@@ -77,6 +77,10 @@ export class PostsService implements CanActivate {
}
}
});
this.reload_config.subscribe(yes_reload => {
if (yes_reload) { this.reloadConfig(); }
});
}
canActivate(route, state): Promise<boolean> {
return new Promise(resolve => {
@@ -103,6 +107,7 @@ export class PostsService implements CanActivate {
const result = !this.debugMode ? res['config_file'] : res;
if (result) {
this.config = result['YoutubeDLMaterial'];
this.config_reloaded = true;
}
});
}