Skip to content

A feature-rich command-line audio/video downloader

[twitcasting] Enforce UTF-8 for POST payload (#2521)

Lesmiscore (Naoya Ozaki)5a13fdd2254d
diff --git a/yt_dlp/extractor/twitcasting.py b/yt_dlp/extractor/twitcasting.py
index 5eb3926d64..8c2235a8ec 100644
--- a/yt_dlp/extractor/twitcasting.py
+++ b/yt_dlp/extractor/twitcasting.py
@@ -85,7 +85,7 @@ class TwitCastingIE(InfoExtractor):
if video_password:
request_data = urlencode_postdata({
'password': video_password,
- })
+ }, encoding='utf-8')
webpage = self._download_webpage(
url, video_id, data=request_data,
headers={'Origin': 'https://twitcasting.tv'})