Core: re-apply YouTube config (API key) on reload
reloadConfig/updateConfig updated the network proxy but never re-pushed the YouTube settings, so editing youtubeApiKey and reloading had no effect — the YouTube client kept its startup key. Add MusicManager::applyYouTubeConfig() (API key, cookies, concurrency, URL shortening; empty key clears it -> yt-dlp fallback) and call it from both reloadConfig and updateConfig. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
1 parent
7e3081ecd1
commit
5796ccbc74
3 files changed
+36
No files matched your search
@@ -834,6 +834,7 @@ namespace Echoion::Core
|
||||
// yt-dlp, ffmpeg), not just the HTTP client.
|
||||
if (musicManager_) {
|
||||
musicManager_->applyNetworkConfig(config.network);
|
||||
musicManager_->applyYouTubeConfig(config.youtube);
|
||||
} else if (networkClient_) {
|
||||
networkClient_->setProxy(config.network.proxy);
|
||||
}
|
||||
@@ -916,6 +917,7 @@ namespace Echoion::Core
|
||||
// config copy. Without this the YouTube API kept using the old/no proxy.
|
||||
if (musicManager_) {
|
||||
musicManager_->applyNetworkConfig(config_.network);
|
||||
musicManager_->applyYouTubeConfig(config_.youtube);
|
||||
} else if (networkClient_) {
|
||||
networkClient_->setProxy(config_.network.proxy);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user