Merge pull request 'Check if TTS is disabled before adding messages' (#8) from Tsudico/joyful:no-tts-fix into main
Reviewed-on: https://codeberg.org/annabunches/joyful/pulls/8 Reviewed-by: annabunches <annabunches@noreply.codeberg.org>
This commit is contained in:
commit
add27f17e2
1 changed files with 5 additions and 3 deletions
|
|
@ -53,10 +53,12 @@ func main() {
|
|||
rules, eventChannel, cancel, wg := loadRules(config, pDevices, vDevicesByName, modes)
|
||||
|
||||
// initialize TTS phrases for modes
|
||||
if !ttsOps.Disabled {
|
||||
for _, m := range modes {
|
||||
tts.AddMessage(m)
|
||||
logger.LogDebugf("Added TTS message '%s'", m)
|
||||
}
|
||||
}
|
||||
|
||||
fmt.Println("Joyful Running! Press Ctrl+C to quit. Press Enter to reload rules.")
|
||||
if len(modes) > 0 {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue