[extractor] Add default parameter to _search_json (#4057)
Authored by: pukkandan, coletdjnz
This commit is contained in:
parent
9fde8a6b12
commit
f0bc6e2019
2 changed files with 26 additions and 7 deletions
|
|
@ -486,9 +486,9 @@ class YoutubeWebArchiveIE(InfoExtractor):
|
|||
search_meta = ((lambda x: self._html_search_meta(x, webpage, default=None)) if webpage else (lambda x: None))
|
||||
player_response = self._search_json(
|
||||
self._YT_INITIAL_PLAYER_RESPONSE_RE, webpage, 'initial player response',
|
||||
video_id, fatal=False)
|
||||
video_id, default={})
|
||||
initial_data = self._search_json(
|
||||
self._YT_INITIAL_DATA_RE, webpage, 'initial data', video_id, fatal=False)
|
||||
self._YT_INITIAL_DATA_RE, webpage, 'initial data', video_id, default={})
|
||||
|
||||
initial_data_video = traverse_obj(
|
||||
initial_data, ('contents', 'twoColumnWatchNextResults', 'results', 'results', 'contents', ..., 'videoPrimaryInfoRenderer'),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue