Merge pull request #49 from subalterngames:speech_dispatcher_voices_panic

Fixed a panic in SpeechDispatcher.voices()
This commit is contained in:
Nolan Darilek 2024-02-09 10:59:04 -06:00 committed by GitHub
commit 9e1476fd36
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 0 deletions

View File

@ -188,6 +188,7 @@ impl Backend for SpeechDispatcher {
.0
.list_synthesis_voices()?
.iter()
.filter(|v| LanguageTag::parse(v.language.clone()).is_ok())
.map(|v| Voice {
id: v.name.clone(),
name: v.name.clone(),