logo

youtube-dl

[mirror] Download/Watch videos from video hosters
commit: 66b686727b198a6b14ddcbcfdcbaadd5b203362f
parent 717ea4e14e59bded0c2fb20e84b6513d82644b43
Author: aeph6Ee0 <aeph6Ee0@users.noreply.github.com>
Date:   Sat,  7 Apr 2018 22:09:42 +0200

[extractor/common] Relax JSON-LD context check (closes #16006)


Diffstat:

Myoutube_dl/extractor/common.py2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py @@ -1025,7 +1025,7 @@ class InfoExtractor(object): }) for e in json_ld: - if e.get('@context') == 'http://schema.org': + if isinstance(e.get('@context'), compat_str) and re.match(r'^https?://schema.org/?$', e.get('@context')): item_type = e.get('@type') if expected_type is not None and expected_type != item_type: return info