From 77541837e5cb27e8e5d322d7c2ecb08f8823a757 Mon Sep 17 00:00:00 2001 From: codesparkle Date: Mon, 19 May 2014 22:17:54 +1000 Subject: [PATCH] The opening curly brace, '{', is a regex reserved control character, so it needs to be escaped (see http://stackoverflow.com/a/400316/1106367) Minor improvements: no need to sort the whole list if all we need is the maximum element, also instead of reinventing the wheel we can use utils to get indices from qualities. --- youtube_dl/extractor/ndr.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/youtube_dl/extractor/ndr.py b/youtube_dl/extractor/ndr.py index 53b34f5e6..3d6096e46 100644 --- a/youtube_dl/extractor/ndr.py +++ b/youtube_dl/extractor/ndr.py @@ -7,6 +7,7 @@ from .common import InfoExtractor from ..utils import ( ExtractorError, int_or_none, + qualities, ) @@ -57,7 +58,7 @@ class NDRIE(InfoExtractor): formats = [] - mp3_url = re.search(r'''{src:'(?P