@webex/web-client-media-engine 3.31.1 → 3.31.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/cjs/index.js CHANGED
@@ -14829,7 +14829,7 @@ class SendSlot {
14829
14829
  }
14830
14830
  }
14831
14831
 
14832
- const organizeTransceiverStats = (sendTransceivers, recvTransceivers) => __awaiter$1(void 0, void 0, void 0, function* () {
14832
+ const organizeTransceiverStats = (sendTransceivers, recvTransceivers, peerConnectionStats) => __awaiter$1(void 0, void 0, void 0, function* () {
14833
14833
  const result = {
14834
14834
  audio: {
14835
14835
  senders: [],
@@ -14857,6 +14857,7 @@ const organizeTransceiverStats = (sendTransceivers, recvTransceivers) => __await
14857
14857
  currentDirection: 'sendonly',
14858
14858
  localTrackLabel: (_a = transceiver.publishedStream) === null || _a === void 0 ? void 0 : _a.label,
14859
14859
  };
14860
+ item.report.set(peerConnectionStats.get('id'), peerConnectionStats);
14860
14861
  if (mediaType === exports.MediaType.AudioMain) {
14861
14862
  result.audio.senders.push(item);
14862
14863
  }
@@ -14879,6 +14880,7 @@ const organizeTransceiverStats = (sendTransceivers, recvTransceivers) => __await
14879
14880
  currentDirection: 'recvonly',
14880
14881
  localTrackLabel: (_b = t.receiveSlot.stream.getTracks()[0]) === null || _b === void 0 ? void 0 : _b.label,
14881
14882
  };
14883
+ item.report.set(peerConnectionStats.get('id'), peerConnectionStats);
14882
14884
  if (mediaType === exports.MediaType.AudioMain) {
14883
14885
  result.audio.receivers.push(item);
14884
14886
  }
@@ -15790,7 +15792,9 @@ SCTP Max Message Size: ${maxMessageSize}`);
15790
15792
  }
15791
15793
  getTransceiverStats() {
15792
15794
  return __awaiter$1(this, void 0, void 0, function* () {
15793
- return organizeTransceiverStats(this.sendTransceivers, this.recvTransceivers);
15795
+ const stats = yield this.getStats();
15796
+ const peerConnectionStats = [...stats.values()].find((stat) => stat.type === 'peer-connection');
15797
+ return organizeTransceiverStats(this.sendTransceivers, this.recvTransceivers, peerConnectionStats);
15794
15798
  });
15795
15799
  }
15796
15800
  preProcessStats(stats) {