fix unavailable video crash

This commit is contained in:
Cyberes 2023-05-06 18:48:35 -06:00
parent 77c2202624
commit 5379207af6
1 changed files with 2 additions and 4 deletions

View File

@ -90,10 +90,8 @@ def download_video(args) -> dict:
output_dict['video_critical_err_msg_short'].append('unavailable.')
return output_dict
# Clean the strings of forign languages
# Clean of forign languages
video['title'] = unidecode(video['title'])
video['uploader'] = unidecode(video['uploader'])
# Get a bar
locked = False
if len(kwargs['bars']):
@ -123,7 +121,7 @@ def download_video(args) -> dict:
# We created a new dict
video['title'] = unidecode(video['title'])
video['uploader'] = unidecode(video['uploader'])
video['uploader'] = unidecode(video['uploader']) # now the additional info is present since we fetched it
video_filename = remove_special_chars_linux(ydl.get_output_templ(video_id=video['id'], title=video['title'], uploader=video['uploader'], uploader_id=video['uploader_id'], include_ext=False), special_chars=['/'])