1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-09-03 08:35:32 +00:00

[downloader/mhtml] Fix fragments with absolute urls (#3044)

Authored-by: coletdjnz
This commit is contained in:
coletdev
2022-03-14 11:03:40 +13:00
committed by GitHub
parent 17322130a9
commit b3edc8068e
3 changed files with 7 additions and 3 deletions

View File

@ -166,7 +166,11 @@ body > figure > img {
if (i + 1) <= ctx['fragment_index']:
continue
fragment_url = urljoin(fragment_base_url, fragment['path'])
fragment_url = fragment.get('url')
if not fragment_url:
assert fragment_base_url
fragment_url = urljoin(fragment_base_url, fragment['path'])
success, frag_content = self._download_fragment(ctx, fragment_url, info_dict)
if not success:
continue