diff options
author | Yen Chi Hsuan <yan12125@gmail.com> | 2017-01-05 18:45:26 +0800 |
---|---|---|
committer | Yen Chi Hsuan <yan12125@gmail.com> | 2017-01-05 18:50:34 +0800 |
commit | 24d8a75982de3fd2fefd2c0d4a1248d03997d843 (patch) | |
tree | 4b87954c4969353d4d6d0a0eb6aaf8c0082b84a7 /youtube_dl | |
parent | 7232bb299b69ee0cf8634a0ebf26f15ecb476a42 (diff) |
[discoverygo] Fix JSON data parsing
HTMLParser, which is used by extract_attributes, already unescapes
attribute values with HTMLParser.unescape. They shouldn't be unescaped
again, to there may be parsing errors.
Ref: #11219, #11522
Diffstat (limited to 'youtube_dl')
-rw-r--r-- | youtube_dl/extractor/discoverygo.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/youtube_dl/extractor/discoverygo.py b/youtube_dl/extractor/discoverygo.py index c4e83b2c3..2042493a8 100644 --- a/youtube_dl/extractor/discoverygo.py +++ b/youtube_dl/extractor/discoverygo.py @@ -6,7 +6,6 @@ from ..utils import ( extract_attributes, int_or_none, parse_age_limit, - unescapeHTML, ExtractorError, ) @@ -49,7 +48,7 @@ class DiscoveryGoIE(InfoExtractor): webpage, 'video container')) video = self._parse_json( - unescapeHTML(container.get('data-video') or container.get('data-json')), + container.get('data-video') or container.get('data-json'), display_id) title = video['name'] |