mimbres commited on
Commit
bd69fba
1 Parent(s): 0e86351

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -66,7 +66,8 @@ def prepare_media(source_path_or_url: os.PathLike,
66
  if source_type == 'audio_filepath':
67
  audio_file = source_path_or_url
68
  elif source_type == 'youtube_url':
69
- os.remove('/download/yt_audio.mp3')
 
70
  # # Download from youtube
71
  with open(log_file, 'w') as lf:
72
  audio_file = './downloaded/yt_audio'
 
66
  if source_type == 'audio_filepath':
67
  audio_file = source_path_or_url
68
  elif source_type == 'youtube_url':
69
+ if os.path.exists('/download/yt_audio.mp3'):
70
+ os.remove('/download/yt_audio.mp3')
71
  # # Download from youtube
72
  with open(log_file, 'w') as lf:
73
  audio_file = './downloaded/yt_audio'