diff options
author | pukkandan <pukkandan.ytdlp@gmail.com> | 2022-06-19 06:45:35 +0530 |
---|---|---|
committer | pukkandan <pukkandan.ytdlp@gmail.com> | 2022-06-19 06:46:46 +0530 |
commit | f254d6ccd9afd4f3f84bf6cb897bed55517f8229 (patch) | |
tree | c29e21385dd0501411d26e4291136c3eeff191ce /yt_dlp/extractor/dropbox.py | |
parent | f0bc6e2019a2f81d358ebddc4ae4cf8e9e4ed905 (diff) | |
download | hypervideo-pre-f254d6ccd9afd4f3f84bf6cb897bed55517f8229.tar.lz hypervideo-pre-f254d6ccd9afd4f3f84bf6cb897bed55517f8229.tar.xz hypervideo-pre-f254d6ccd9afd4f3f84bf6cb897bed55517f8229.zip |
[extractor/dropbox] Extract the correct `mountComponent`
Diffstat (limited to 'yt_dlp/extractor/dropbox.py')
-rw-r--r-- | yt_dlp/extractor/dropbox.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/yt_dlp/extractor/dropbox.py b/yt_dlp/extractor/dropbox.py index 6ac0c713a..0d12513b2 100644 --- a/yt_dlp/extractor/dropbox.py +++ b/yt_dlp/extractor/dropbox.py @@ -53,8 +53,8 @@ class DropboxIE(InfoExtractor): else: raise ExtractorError('Password protected video, use --video-password <password>', expected=True) - json_string = self._html_search_regex(r'InitReact\.mountComponent\(.*?,\s*(\{.+\})\s*?\)', webpage, 'Info JSON') - info_json = self._parse_json(json_string, video_id).get('props') + info_json = self._search_json(r'InitReact\.mountComponent\(.*?,', webpage, 'mountComponent', video_id, + contains_pattern=r'.+?"preview".+?', end_pattern=r'\)')['props'] transcode_url = traverse_obj(info_json, ((None, 'preview'), 'file', 'preview', 'content', 'transcode_url'), get_all=False) formats, subtitles = self._extract_m3u8_formats_and_subtitles(transcode_url, video_id) |