gabrielchua commited on
Commit
5deb312
1 Parent(s): 67bd675

fix language selection

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -89,7 +89,7 @@ def generate_podcast(
89
  text = ""
90
 
91
  # Check if the selected language is supported by MeloTTS when not using advanced audio
92
- if not use_advanced_audio and language not in MELO_TTS_LANGUAGE_MAPPING:
93
  raise gr.Error(f"The selected language '{language}' is not supported without advanced audio generation. Please enable advanced audio generation or choose a supported language.")
94
 
95
  # Check if at least one input is provided
 
89
  text = ""
90
 
91
  # Check if the selected language is supported by MeloTTS when not using advanced audio
92
+ if not use_advanced_audio and language in ['German', 'Hindi', 'Italian', 'Polish', 'Portuguese', 'Russian', 'Turkish']:
93
  raise gr.Error(f"The selected language '{language}' is not supported without advanced audio generation. Please enable advanced audio generation or choose a supported language.")
94
 
95
  # Check if at least one input is provided