diff --git a/lib/tasks/cognigy/speech-config.js b/lib/tasks/cognigy/speech-config.js index f83a51e6..d3ba7f25 100644 --- a/lib/tasks/cognigy/speech-config.js +++ b/lib/tasks/cognigy/speech-config.js @@ -23,8 +23,8 @@ class SpeechConfig extends Emitter { this.sessionConfig, changedConfig, (objValue, sourceValue) => { - if(isArray(objValue)){ - if(isArray(sourceValue)){ + if (isArray(objValue)) { + if (isArray(sourceValue)) { return sourceValue; } return objValue; diff --git a/lib/tasks/gather.js b/lib/tasks/gather.js index 0999d6c3..3c78c5b8 100644 --- a/lib/tasks/gather.js +++ b/lib/tasks/gather.js @@ -88,6 +88,7 @@ class TaskGather extends Task { const startListening = (cs, ep) => { this._startTimer(); if (this.input.includes('speech') && !this.listenDuringPrompt) { + this.logger.debug('listening after speech 1'); this._initSpeech(cs, ep) .then(() => { this._startTranscribing(ep); @@ -106,6 +107,7 @@ class TaskGather extends Task { this.logger.debug('Gather: say task completed'); if (!this.killed) { if (this.listenAfterSpeech === true) { + this.logger.debug('listening after speech 2'); startListening(cs, ep); } else { this.notifyTaskDone(); @@ -119,6 +121,7 @@ class TaskGather extends Task { if (err) return this.logger.error({err}, 'Gather:exec Error playing url'); if (!this.killed) { if (this.listenAfterSpeech === true) { + this.logger.debug('listening after speech 3'); startListening(cs, ep); } else { this.notifyTaskDone(); @@ -130,6 +133,7 @@ class TaskGather extends Task { else startListening(cs, ep); if (this.input.includes('speech') && this.listenDuringPrompt) { + this.logger.debug('listening after speech 4'); await this._initSpeech(cs, ep); this._startTranscribing(ep); updateSpeechCredentialLastUsed(this.sttCredentials.speech_credential_sid)