Fix utils.strip_jsonp
authorFilippo Valsorda <filippo.valsorda@gmail.com>
Sun, 13 Jul 2014 22:41:23 +0000 (00:41 +0200)
committerFilippo Valsorda <filippo.valsorda@gmail.com>
Sun, 13 Jul 2014 22:41:23 +0000 (00:41 +0200)
youtube_dl/utils.py

index a2890b76427f4c51e80b45528e133fa9ae299c35..64a9618ca62493f893af16b31b3fbd331bbdc1e7 100644 (file)
@@ -1428,7 +1428,7 @@ US_RATINGS = {
 
 
 def strip_jsonp(code):
-    return re.sub(r'(?s)^[a-zA-Z0-9_]+\s*\(\s*(.*)\)\s*?\s*$', r'\1', code)
+    return re.sub(r'(?s)^[a-zA-Z0-9_]+\s*\(\s*(.*)\);?\s*?\s*$', r'\1', code)
 
 
 def qualities(quality_ids):