From 11a8f1679bdfad55a95dc42d38962910b6cb98a6 Mon Sep 17 00:00:00 2001 From: Mattias Wadman Date: Mon, 23 Jan 2017 20:42:31 +0100 Subject: [PATCH] [infoq] Use _hidden_inputs instead of messy regex --- youtube_dl/extractor/infoq.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/youtube_dl/extractor/infoq.py b/youtube_dl/extractor/infoq.py index 84799271e..d63e95854 100644 --- a/youtube_dl/extractor/infoq.py +++ b/youtube_dl/extractor/infoq.py @@ -74,7 +74,8 @@ class InfoQIE(BokeCCBaseIE): }] def _extract_http_audio(self, webpage): - http_audio_url = self._search_regex(r']*?name="filename"[^>]*?value="([^\"]+)"[^>]*?>', webpage, 'audio URL', fatal=False) + fields = self._hidden_inputs(webpage) + http_audio_url = fields['filename'] if http_audio_url is None: return [] # base URL is found in the Location header in the response returned by