1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-10-31 14:45:14 +00:00

[outtmpl] Ensure ASCII in json and add option for Unicode

Closes #5236
This commit is contained in:
pukkandan
2022-10-14 11:48:45 +05:30
parent 6dca2aa66d
commit 9b9dad119a
2 changed files with 2 additions and 2 deletions

View File

@@ -1249,7 +1249,7 @@ class YoutubeDL:
elif fmt[-1] == 'j': # json
value, fmt = json.dumps(
value, default=_dumpjson_default,
indent=4 if '#' in flags else None, ensure_ascii=False), str_fmt
indent=4 if '#' in flags else None, ensure_ascii='+' not in flags), str_fmt
elif fmt[-1] == 'h': # html
value, fmt = escapeHTML(str(value)), str_fmt
elif fmt[-1] == 'q': # quoted