@babblevoice/babble-drachtio-callmanager 3.6.14 → 3.6.16

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/lib/call.js CHANGED
@@ -3447,6 +3447,8 @@ class call {
3447
3447
  if( !this.channels.audio ) return
3448
3448
  if( !this.channels.audio.local ) return
3449
3449
 
3450
+ const oldsdp = this.sdp.local
3451
+
3450
3452
  this.sdp.local = sdpgen.create()
3451
3453
  .addcodecs( this.options.preferedcodecs )
3452
3454
  .setaudioport( this.channels.audio.local.port )
@@ -3454,6 +3456,9 @@ class call {
3454
3456
 
3455
3457
  this.#checkandadd2833()
3456
3458
 
3459
+ /* maintain selection */
3460
+ if( oldsdp && oldsdp.selected ) this.sdp.local.select( oldsdp.selected )
3461
+
3457
3462
  /* DTLS is only supported ( outbound ) on websocket connections */
3458
3463
  if( this._iswebrtc ) {
3459
3464
  this.channels.secure.audio.offer = true
package/lib/sdp.js CHANGED
@@ -739,7 +739,7 @@ class sdp {
739
739
  }
740
740
 
741
741
  /** only return selected */
742
- if( this.#selected ) {
742
+ if( undefined !== this.#selected ) {
743
743
  co.media.forEach( ( media ) => {
744
744
  media.rtp = media.rtp.filter( item => [ this.#selected, rfc2833 ].includes( item.payload ))
745
745
  media.fmtp = media.fmtp.filter( item => [ this.#selected, rfc2833 ].includes( item.payload ))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@babblevoice/babble-drachtio-callmanager",
3
- "version": "3.6.14",
3
+ "version": "3.6.16",
4
4
  "description": "Call processing to create a PBX",
5
5
  "main": "index.js",
6
6
  "scripts": {