@reactoo/watchtogether-sdk-js 2.7.45 → 2.7.47

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reactoo/watchtogether-sdk-js",
3
- "version": "2.7.45",
3
+ "version": "2.7.47",
4
4
  "description": "Javascript SDK for Reactoo",
5
5
  "main": "src/index.js",
6
6
  "unpkg": "dist/watchtogether-sdk.min.js",
@@ -113,7 +113,7 @@ class Iot {
113
113
  return new Promise((resolve, reject) => {
114
114
  const timeoutId = setTimeout(() => {
115
115
  reject(new Error('Disconnect timeout'));
116
- }, 5); // 5 seconds timeout is enough
116
+ }, 5000); // 5 seconds timeout is enough
117
117
  this.connection.disconnect()
118
118
  .then((r) => {
119
119
  clearTimeout(timeoutId);
@@ -1804,6 +1804,7 @@ class RoomSession {
1804
1804
  participantStats.stats.forEach(report => {
1805
1805
 
1806
1806
  const simulcastConfigForSource = this._findSimulcastConfig(participantStats.source, this.simulcastSettings);
1807
+ const defaultSelectedSubstream = handle.webrtcStuff?.overriddenSimulcastMode[participantStats.mid]?.defaultSubstream || simulcastConfigForSource?.defaultSubstream;
1807
1808
  const simulcastMode = handle.webrtcStuff?.overriddenSimulcastMode[participantStats.mid]?.mode || simulcastConfigForSource?.mode ;
1808
1809
 
1809
1810
  if(report.type === 'inbound-rtp' && report.kind === 'video') {
@@ -1828,6 +1829,7 @@ class RoomSession {
1828
1829
  }
1829
1830
 
1830
1831
  stats.selectedSubstream = handle.webrtcStuff.selectedSubstream[participantStats.mid];
1832
+ stats.desiredSubstream = defaultSelectedSubstream;
1831
1833
  stats.simulcastMode = simulcastMode;
1832
1834
 
1833
1835
  });