From d5d0d5fb8d30c0d49f5411270eb1f44bddd4a74a Mon Sep 17 00:00:00 2001 From: Quan HL Date: Fri, 8 Nov 2024 15:05:06 +0700 Subject: [PATCH] wip --- lib/utils.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/utils.js b/lib/utils.js index 0d34338..44df2a8 100644 --- a/lib/utils.js +++ b/lib/utils.js @@ -36,15 +36,15 @@ function makeRtpEngineOpts(req, srcIsUsingSrtp, dstIsUsingSrtp, padCrypto, teams common, uas: { tag: from.params.tag, - mediaOpts: { - ...srcOpts, - ...(process.env.JAMBONES_ACCEPT_AND_TRANSCODE && - { codec: { mask: process.env.JAMBONES_ACCEPT_AND_TRANSCODE, transcode: 'pcmu,pcma' } }) - } + mediaOpts: srcOpts }, uac: { tag: null, - mediaOpts: dstOpts + mediaOpts: { + ...dstOpts, + ...(process.env.JAMBONES_CODEC_OFFER_WITH_ORDER && + { codec: { offer: process.env.JAMBONES_CODEC_OFFER_WITH_ORDER.split(','), strip: 'all' } }), + } } }; }