mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-08 09:10:09 +01:00
[ndr] Fix description and upload date extraction (Closes #7893)
This commit is contained in:
parent
016dd82050
commit
9796a9b20c
@ -88,10 +88,10 @@ def _extract_embed(self, webpage, display_id):
|
|||||||
'embedURL', webpage, 'embed URL', fatal=True)
|
'embedURL', webpage, 'embed URL', fatal=True)
|
||||||
description = self._search_regex(
|
description = self._search_regex(
|
||||||
r'<p[^>]+itemprop="description">([^<]+)</p>',
|
r'<p[^>]+itemprop="description">([^<]+)</p>',
|
||||||
webpage, 'description', fatal=False)
|
webpage, 'description', default=None) or self._og_search_description(webpage)
|
||||||
timestamp = parse_iso8601(
|
timestamp = parse_iso8601(
|
||||||
self._search_regex(
|
self._search_regex(
|
||||||
r'<span itemprop="datePublished" content="([^"]+)">',
|
r'<span[^>]+itemprop="(?:datePublished|uploadDate)"[^>]+content="([^"]+)"',
|
||||||
webpage, 'upload date', fatal=False))
|
webpage, 'upload date', fatal=False))
|
||||||
return {
|
return {
|
||||||
'_type': 'url_transparent',
|
'_type': 'url_transparent',
|
||||||
|
Loading…
Reference in New Issue
Block a user