1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-02-02 23:52:50 +08:00

[libsyn] fix extracting the JSON data block

The page switched to \r\n Windows line endings.
This commit is contained in:
Paul Wise 2019-01-08 10:18:47 +08:00
parent 6aa12bf34c
commit b46b0ddbd6
No known key found for this signature in database
GPG Key ID: 3116BA5E9FFA69A3

View File

@ -61,7 +61,7 @@ class LibsynIE(InfoExtractor):
# Strip non-breaking and normal spaces
description = description.replace('\u00A0', ' ').strip()
data_json = self._search_regex(r'var\s+playlistItem\s*=\s*(\{.*?\});\n', webpage, 'JSON data block')
data_json = self._search_regex(r'var\s+playlistItem\s*=\s*(\{.*?\});', webpage, 'JSON data block')
data = json.loads(data_json)
formats = [{