Fix impersonate option

This commit is contained in:
you-cant-see-me 2025-05-27 15:56:48 +01:00 committed by GitHub
parent b07db0c9e3
commit cdcb6691b0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -299,8 +299,8 @@ class DownloadQueue:
'ignore_no_formats_error': True, 'ignore_no_formats_error': True,
'noplaylist': playlist_strict_mode, 'noplaylist': playlist_strict_mode,
'paths': {"home": self.config.DOWNLOAD_DIR, "temp": self.config.TEMP_DIR}, 'paths': {"home": self.config.DOWNLOAD_DIR, "temp": self.config.TEMP_DIR},
**({'impersonate': yt_dlp.networking.impersonate.ImpersonateTarget.from_str(self.config.YTDL_OPTIONS['impersonate'])} if 'impersonate' in self.config.YTDL_OPTIONS else {}),
**self.config.YTDL_OPTIONS, **self.config.YTDL_OPTIONS,
**({'impersonate': yt_dlp.networking.impersonate.ImpersonateTarget.from_str(self.config.YTDL_OPTIONS['impersonate'])} if 'impersonate' in self.config.YTDL_OPTIONS else {}),
}).extract_info(url, download=False) }).extract_info(url, download=False)
def __calc_download_path(self, quality, format, folder): def __calc_download_path(self, quality, format, folder):