@onereach/step-voice 6.0.11 → 6.0.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dst/Global Command.d.ts +1 -0
- package/dst/Global Command.js +6 -4
- package/dst/voice.js +0 -1
- package/package.json +1 -1
package/dst/Global Command.d.ts
CHANGED
package/dst/Global Command.js
CHANGED
|
@@ -77,10 +77,8 @@ class GlobalCommand extends voice_1.default {
|
|
|
77
77
|
});
|
|
78
78
|
this.triggers.local(`in/voice/${call.id}`, async (event) => {
|
|
79
79
|
switch (event.params.type) {
|
|
80
|
-
case 'hangup':
|
|
81
|
-
await this.hangup(call);
|
|
82
|
-
return;
|
|
83
|
-
}
|
|
80
|
+
case 'hangup':
|
|
81
|
+
return await this.hangup(call);
|
|
84
82
|
case 'avm-detected':
|
|
85
83
|
return await this.exitThread(event, 'AMD', 'AMD');
|
|
86
84
|
case 'digit':
|
|
@@ -147,6 +145,10 @@ class GlobalCommand extends voice_1.default {
|
|
|
147
145
|
});
|
|
148
146
|
}
|
|
149
147
|
async hangup(call) {
|
|
148
|
+
if (this.event.params.zombie) {
|
|
149
|
+
this.log.debug('ignore zombie hangup');
|
|
150
|
+
return this.exitFlow();
|
|
151
|
+
}
|
|
150
152
|
await this.handleHangup(call);
|
|
151
153
|
const isHangedUpByBot = call.sessionEndedBy === 'Bot';
|
|
152
154
|
const hangUpType = isHangedUpByBot ? 'bot hang up' : 'user hang up';
|
package/dst/voice.js
CHANGED
|
@@ -364,7 +364,6 @@ class VoiceStep extends step_1.default {
|
|
|
364
364
|
// eslint-disable-next-line @typescript-eslint/no-dynamic-delete
|
|
365
365
|
delete this.waits[this.event.name];
|
|
366
366
|
}
|
|
367
|
-
this.log.debug('>>> sleepUntilHangup', { name: this.event.name, waits: this.waits });
|
|
368
367
|
}
|
|
369
368
|
}
|
|
370
369
|
exports.default = VoiceStep;
|