1
0
mirror of https://github.com/l1ving/youtube-dl synced 2025-01-23 17:33:11 +08:00

regex in utils polished to beauty

This commit is contained in:
Ales Jirasek 2019-02-05 21:47:09 +01:00
parent 8559fcbd54
commit 7d904e5f01

View File

@ -183,7 +183,7 @@ DATE_FORMATS_MONTH_FIRST.extend([
])
PACKED_CODES_RE = r"}\('(.+)',(\d+),(\d+),'([^']+)'\.split\('\|'\)"
JSON_LD_RE = r'(?is)<script[^>]+type=(["\']|)application/ld\+json\1[^>]*>(?P<json_ld>.+?)</script>'
JSON_LD_RE = r'(?is)<script[^>]+type=(["\']?)application/ld\+json\1[^>]*>(?P<json_ld>.+?)</script>'
def preferredencoding():