diff --git a/lib/tasks/say.js b/lib/tasks/say.js index 7ee258c4..691e98e1 100644 --- a/lib/tasks/say.js +++ b/lib/tasks/say.js @@ -21,9 +21,9 @@ class TaskSay extends Task { const {updateSpeechCredentialLastUsed} = require('../utils/db-utils')(this.logger, srf); const {writeAlerts, AlertType, stats} = srf.locals; const {synthAudio} = srf.locals.dbHelpers; - const vendor = this.synthesizer.vendor || cs.speechSynthesisVendor; - const language = this.synthesizer.language || cs.speechSynthesisLanguage ; - const voice = this.synthesizer.voice || cs.speechSynthesisVoice ; + const vendor = this.synthesizer.vendor !== 'default' ? this.synthesizer.vendor : cs.speechSynthesisVendor; + const language = this.synthesizer.language !== 'default' ? this.synthesizer.language : cs.speechSynthesisLanguage ; + const voice = this.synthesizer.voice !== 'default' ? this.synthesizer.voice : cs.speechSynthesisVoice; const engine = this.synthesizer.engine || 'standard'; const salt = cs.callSid; const credentials = cs.getSpeechCredentials(vendor, 'tts');