added support for conference verb

This commit is contained in:
Dave Horton
2020-04-27 11:25:39 -04:00
parent d31c53d383
commit 8ee590172b
27 changed files with 888 additions and 133 deletions

View File

@@ -14,7 +14,7 @@ class TaskPlay extends Task {
get name() { return TaskName.Play; }
async exec(cs, ep) {
super.exec(cs);
await super.exec(cs);
this.ep = ep;
try {
while (!this.killed && this.loop--) {
@@ -26,8 +26,8 @@ class TaskPlay extends Task {
this.emit('playDone');
}
async kill() {
super.kill();
async kill(cs) {
super.kill(cs);
if (this.ep.connected && !this.playComplete) {
this.logger.debug('TaskPlay:kill - killing audio');
await this.ep.api('uuid_break', this.ep.uuid).catch((err) => this.logger.info(err, 'Error killing audio'));