@webex/web-client-media-engine 3.0.1 → 3.0.2

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/dist/esm/index.js CHANGED
@@ -9121,6 +9121,12 @@ function filterCodecs(parsedSdp, allowedCodecs) {
9121
9121
  .filter((codecName) => !allowedLowerCase.includes(codecName.toLowerCase()))
9122
9122
  .forEach((c) => removeCodec(parsedSdp, c));
9123
9123
  }
9124
+ function filterCandidates(parsedSdp) {
9125
+ const supportedTransportTypes = ['udp', 'tcp'];
9126
+ parsedSdp.media.forEach((mline) => {
9127
+ mline.iceInfo.candidates = mline.iceInfo.candidates.filter((candidate) => supportedTransportTypes.includes(candidate.transport.toLowerCase()));
9128
+ });
9129
+ }
9124
9130
  function setMaxBandwidth(parsedSdp, maxBandwidth) {
9125
9131
  parsedSdp.avMedia.forEach((mline) => {
9126
9132
  mline.bandwidth = new BandwidthLine('TIAS', maxBandwidth);
@@ -14284,6 +14290,7 @@ class MultistreamConnection extends EventEmitter$2 {
14284
14290
  const parsedOffer = parse((_a = this.pc.getLocalDescription()) === null || _a === void 0 ? void 0 : _a.sdp);
14285
14291
  const recvTransceiversByMid = new Map([...this.recvTransceivers.values()].flat().map((t) => [t.mid, t]));
14286
14292
  matchMlinesInAnswer(parsedOffer, parsedAnswer, recvTransceiversByMid);
14293
+ filterCandidates(parsedAnswer);
14287
14294
  if (getBrowserDetails().name === 'Firefox') {
14288
14295
  setupBundle(parsedAnswer, this.options.bundlePolicy, this.midPredictor.getMidMap());
14289
14296
  if (this.options.bundlePolicy === 'max-bundle') {