Skip to content

Commit

Permalink
Fixed a bug of switching among voices of the same language
Browse files Browse the repository at this point in the history
  • Loading branch information
mush42 committed Oct 22, 2023
1 parent af78d99 commit a84e19f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions addon/synthDrivers/piper_neural_voices/tts_system.py
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,8 @@ def language(self) -> str:
def language(self, new_language: str):
"""Set the current voice language"""
lang = normalizeLanguage(new_language)
if self.speech_options.voice.language == lang:
return
lang_code = lang.split("-")[0] + "-"
possible_voices = []
for voice in self.voices:
Expand Down

0 comments on commit a84e19f

Please sign in to comment.