@reactoo/watchtogether-sdk-js 2.5.60 → 2.5.61

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.5.60",
3
+ "version": "2.5.61",
4
4
  "description": "Javascript SDK for Reactoo",
5
5
  "main": "src/index.js",
6
6
  "unpkg": "dist/watchtogether-sdk.min.js",
@@ -137,14 +137,14 @@ const syncModule = function ({room, emitter} = {}) {
137
137
  if(position !== null && !isNaN(position)) {
138
138
  return seekBy(position)
139
139
  .then(() => {
140
- const seekDuration = (Date.now() - syncStartTime) / 1000;
140
+ const seekDuration = (Date.now() - syncStartTime);
141
141
  const {position, realPosition, isBufferSufficient} = _playerInterface.getTimeDifference
142
142
  ? _playerInterface.getTimeDifference(syncData.masterFragmentSn, syncData.masterFragmentPos + seekDuration, syncData.ping)
143
143
  : getTimeDifference(syncData.masterFragmentSn, syncData.masterFragmentPos + seekDuration, syncData.ping);
144
144
 
145
145
  const syncPrecision = Math.abs(realPosition);
146
146
  room._log(`Insufficient buffer: `, !isBufferSufficient)
147
- room._log(`Seek duration is ${seekDuration} seconds`);
147
+ room._log(`Seek duration is ${seekDuration / 1000} seconds`);
148
148
  room._log(`Sync precision should be ${syncPrecision}`);
149
149
 
150
150
  const didSyncFail = syncPrecision > maxSyncThreshold;