@rtcstats/rtcstats-shared 2.6.0 → 2.6.1

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.
Files changed (2) hide show
  1. package/dump.js +2 -2
  2. package/package.json +1 -1
package/dump.js CHANGED
@@ -201,11 +201,11 @@ export function internalsToRtcstats(data) {
201
201
  const tracks = [];
202
202
  if (gum.audio_track_info) {
203
203
  const t = JSON.parse(gum.audio_track_info);
204
- tracks.push(['audio', t.id, t.label, gum.stream_id]);
204
+ if (t) tracks.push(['audio', t.id, t.label, gum.stream_id]);
205
205
  }
206
206
  if (gum.video_track_info) {
207
207
  const t = JSON.parse(gum.video_track_info);
208
- tracks.push(['video', t.id, t.label, gum.stream_id]);
208
+ if (t) tracks.push(['video', t.id, t.label, gum.stream_id]);
209
209
  }
210
210
  clientTrace.push({type: baseType + 'OnSuccess', value: tracks, timestamp: gum.timestamp, extra: []});
211
211
  } else if (gum.audio !== undefined || gum.video !== undefined) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtcstats/rtcstats-shared",
3
- "version": "2.6.0",
3
+ "version": "2.6.1",
4
4
  "main": "index.js",
5
5
  "description": "gather WebRTC API traces and statistics",
6
6
  "type": "module",