Support sipindialog for conference (#1050)

* fix: add _onRequestWithinDialog catch block

* feat: support sipindialog for conference

* fix: remove any existing listener before adding new
This commit is contained in:
Anton Voylenko
2025-02-24 20:59:32 +02:00
committed by GitHub
parent 8bed44cce3
commit 69ba18acd1
3 changed files with 30 additions and 5 deletions

View File

@@ -2478,12 +2478,14 @@ Duration=${duration} `
} else if (sip_method === 'MESSAGE') {
res.send(202);
} else {
this.logger.info(`CallSession:_onRequestWithinDialog unsported method: ${req.method}`);
this.logger.warn(`CallSession:_onRequestWithinDialog unsupported method: ${req.method}`);
res.send(501);
return;
}
const params = {sip_method, sip_body: req.body, sip_headers: req.headers};
this.currentTask.performHook(this, this.sipRequestWithinDialogHook, params);
this.currentTask.performHook(this, this.sipRequestWithinDialogHook, params).catch((err) => {
this.logger.error({err}, 'CallSession:_onRequestWithinDialog - error calling sipRequestWithinDialogHook');
});
}
async _onReinvite(req, res) {