Skip to content

Commit 6a5a30f

Browse files
committed
Ensure _type is present in info.json
Closes yt-dlp#2447
1 parent d37707b commit 6a5a30f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

yt_dlp/YoutubeDL.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3211,6 +3211,7 @@ def sanitize_info(info_dict, remove_private_keys=False):
32113211
if info_dict is None:
32123212
return info_dict
32133213
info_dict.setdefault('epoch', int(time.time()))
3214+
info_dict.setdefault('_type', 'video')
32143215
remove_keys = {'__original_infodict'} # Always remove this since this may contain a copy of the entire dict
32153216
keep_keys = ['_type'] # Always keep this to facilitate load-info-json
32163217
if remove_private_keys:

0 commit comments

Comments
 (0)