diff --git a/lib/tasks/cognigy/index.js b/lib/tasks/cognigy/index.js index c3385abf..91edd096 100644 --- a/lib/tasks/cognigy/index.js +++ b/lib/tasks/cognigy/index.js @@ -262,7 +262,7 @@ class Cognigy extends Task { if (evt.data) this.config.update(evt.data); if (text) { - await this._enqueueTask((async() => { + this._enqueueTask((async() => { this.logger.info({text}, 'received text'); const sayTask = this._makeSayTask(text); await sayTask.exec(cs, ep, this); @@ -274,7 +274,7 @@ class Cognigy extends Task { try { switch (evt.data.type) { case 'hangup': - await this._enqueueTask((async() => { + this._enqueueTask((async() => { const hangupTask = this._makeHangupTask(evt.data.reason); await hangupTask.exec(cs, ep, this); this.performAction({cognigyResult: 'hangup Succeeded'}); @@ -285,7 +285,7 @@ class Cognigy extends Task { return; case 'refer': - await this._enqueueTask(async() => { + this._enqueueTask(async() => { const referTask = this._makeReferTask(evt.data.number); await referTask.exect(cs, ep, this); this.performAction({cognigyResult: 'refer succeeded'});