Added additional protections to verify that the DB is initialized before downloader does

Began work on watching entire subscriptions as a playlist

Subscriptions now use the new download manager to download files
This commit is contained in:
Isaac Abadi
2021-08-21 21:54:40 -06:00
parent f7b152fcf6
commit 9f5b6122fa
11 changed files with 151 additions and 85 deletions

View File

@@ -246,11 +246,6 @@ export class MainComponent implements OnInit {
this.useDefaultDownloadingAgent = this.postsService.config['Advanced']['use_default_downloading_agent'];
this.customDownloadingAgent = this.postsService.config['Advanced']['custom_downloading_agent'];
if (this.youtubeSearchEnabled && this.youtubeAPIKey) {
this.youtubeSearch.initializeAPI(this.youtubeAPIKey);
this.attachToInput();
}
// set final cache items
localStorage.setItem('cached_filemanager_enabled', this.fileManagerEnabled.toString());
@@ -330,6 +325,13 @@ export class MainComponent implements OnInit {
this.setCols();
}
ngAfterViewInit() {
if (this.youtubeSearchEnabled && this.youtubeAPIKey) {
this.youtubeSearch.initializeAPI(this.youtubeAPIKey);
this.attachToInput();
}
}
public setCols() {
if (window.innerWidth <= 350) {
this.files_cols = 1;