A feature-rich command-line audio/video downloader
[utils] Strip double spaces in `clean_html`
pukkandan491852273514
diff --git a/yt_dlp/utils.py b/yt_dlp/utils.pyindex 13ad5fd489..fd3912d188 100644--- a/yt_dlp/utils.py+++ b/yt_dlp/utils.py@@ -639,10 +639,9 @@ def clean_html(html):if html is None: # Convenience for sanitizing descriptions etc.return html- # Newline vs <br />- html = html.replace('\n', ' ')- html = re.sub(r'(?u)\s*<\s*br\s*/?\s*>\s*', '\n', html)- html = re.sub(r'(?u)<\s*/\s*p\s*>\s*<\s*p[^>]*>', '\n', html)+ html = re.sub(r'\s+', ' ', html)+ html = re.sub(r'(?u)\s?<\s?br\s?/?\s?>\s?', '\n', html)+ html = re.sub(r'(?u)<\s?/\s?p\s?>\s?<\s?p[^>]*>', '\n', html)# Strip html tagshtml = re.sub('<.*?>', '', html)# Replace html entities