[itv] clean description from HTML tags (closes #27399)
authorRemita Amine <remitamine@gmail.com>
Sun, 13 Dec 2020 08:50:20 +0000 (09:50 +0100)
committerRemita Amine <remitamine@gmail.com>
Sun, 13 Dec 2020 08:51:03 +0000 (09:51 +0100)
youtube_dl/extractor/itv.py

index 08bcc8b685a41a5134d46a620655916f1e2838f3..e86c40b42e5d2db24d03cda7c3915b27b4cf603c 100644 (file)
@@ -7,6 +7,7 @@ import re
 from .common import InfoExtractor
 from .brightcove import BrightcoveNewIE
 from ..utils import (
+    clean_html,
     determine_ext,
     extract_attributes,
     get_element_by_class,
@@ -14,7 +15,6 @@ from ..utils import (
     merge_dicts,
     parse_duration,
     smuggle_url,
-    strip_or_none,
     url_or_none,
 )
 
@@ -146,7 +146,7 @@ class ITVIE(InfoExtractor):
             'formats': formats,
             'subtitles': subtitles,
             'duration': parse_duration(video_data.get('Duration')),
-            'description': strip_or_none(get_element_by_class('episode-info__synopsis', webpage)),
+            'description': clean_html(get_element_by_class('episode-info__synopsis', webpage)),
         }, info)