mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2025-03-09 12:50:23 -05:00
Apply suggestions
This commit is contained in:
parent
6054c7016e
commit
7cb7e57473
1 changed files with 3 additions and 1 deletions
|
@ -4,7 +4,9 @@
|
||||||
from ..utils import (
|
from ..utils import (
|
||||||
extract_attributes,
|
extract_attributes,
|
||||||
unified_timestamp,
|
unified_timestamp,
|
||||||
|
url_or_none,
|
||||||
)
|
)
|
||||||
|
from ..utils.traversal import traverse_obj
|
||||||
|
|
||||||
|
|
||||||
class N1InfoAssetIE(InfoExtractor):
|
class N1InfoAssetIE(InfoExtractor):
|
||||||
|
@ -180,7 +182,7 @@ def _real_extract(self, url):
|
||||||
'url': video_data.get('data-url'),
|
'url': video_data.get('data-url'),
|
||||||
'id': video_data.get('id'),
|
'id': video_data.get('id'),
|
||||||
'title': title,
|
'title': title,
|
||||||
'thumbnail': video_data.get('data-thumbnail') or video_data.get('data-default_thumbnail'),
|
'thumbnail': traverse_obj(video_data, (('data-thumbnail', 'data-default_thumbnail'), {url_or_none}, any)),
|
||||||
'timestamp': timestamp,
|
'timestamp': timestamp,
|
||||||
'ie_key': 'N1InfoAsset',
|
'ie_key': 'N1InfoAsset',
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in a new issue