AdarshJi commited on
Commit
069dbf4
1 Parent(s): 8c044c5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -3
app.py CHANGED
@@ -12,9 +12,7 @@ async def TextToAudioFile(text: str, model: str) -> str:
12
  """Converts text to an audio file and returns its base64 encoded string."""
13
  file_path = "main.mp3"
14
 
15
- # Remove existing file if it exists
16
- if os.path.exists(file_path):
17
- os.remove(file_path)
18
 
19
  # Convert text to audio
20
  communicate = edge_tts.Communicate(text, voice=model, pitch='+5Hz', rate='+10%')
 
12
  """Converts text to an audio file and returns its base64 encoded string."""
13
  file_path = "main.mp3"
14
 
15
+
 
 
16
 
17
  # Convert text to audio
18
  communicate = edge_tts.Communicate(text, voice=model, pitch='+5Hz', rate='+10%')