@dcl/ecs 7.26.1-32844959441.commit-a2ccd0b → 7.26.1-32861215853.commit-9eb2738

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.
@@ -35,7 +35,7 @@ export class ReadWriteByteBuffer {
35
35
  constructor(buffer, readingOffset, writingOffset) {
36
36
  _ReadWriteByteBuffer_instances.add(this);
37
37
  this._buffer = buffer || new Uint8Array(defaultInitialCapacity);
38
- this.view = new DataView(this._buffer.buffer, this._buffer.byteOffset);
38
+ this.view = new DataView(this._buffer.buffer, this._buffer.byteOffset, this._buffer.byteLength);
39
39
  this.woffset = writingOffset ?? (buffer ? this._buffer.length : null) ?? 0;
40
40
  this.roffset = readingOffset ?? 0;
41
41
  }
@@ -230,9 +230,8 @@ _ReadWriteByteBuffer_instances = new WeakSet(), _ReadWriteByteBuffer_woAdd = fun
230
230
  const newsize = getNextSize(this._buffer.byteLength, this.woffset + amount);
231
231
  const newBuffer = new Uint8Array(newsize);
232
232
  newBuffer.set(this._buffer);
233
- const oldOffset = this._buffer.byteOffset;
234
233
  this._buffer = newBuffer;
235
- this.view = new DataView(this._buffer.buffer, oldOffset);
234
+ this.view = new DataView(this._buffer.buffer, this._buffer.byteOffset, this._buffer.byteLength);
236
235
  }
237
236
  this.woffset += amount;
238
237
  return this.woffset - amount;
@@ -61,7 +61,7 @@ class ReadWriteByteBuffer {
61
61
  constructor(buffer, readingOffset, writingOffset) {
62
62
  _ReadWriteByteBuffer_instances.add(this);
63
63
  this._buffer = buffer || new Uint8Array(defaultInitialCapacity);
64
- this.view = new DataView(this._buffer.buffer, this._buffer.byteOffset);
64
+ this.view = new DataView(this._buffer.buffer, this._buffer.byteOffset, this._buffer.byteLength);
65
65
  this.woffset = writingOffset ?? (buffer ? this._buffer.length : null) ?? 0;
66
66
  this.roffset = readingOffset ?? 0;
67
67
  }
@@ -257,9 +257,8 @@ _ReadWriteByteBuffer_instances = new WeakSet(), _ReadWriteByteBuffer_woAdd = fun
257
257
  const newsize = getNextSize(this._buffer.byteLength, this.woffset + amount);
258
258
  const newBuffer = new Uint8Array(newsize);
259
259
  newBuffer.set(this._buffer);
260
- const oldOffset = this._buffer.byteOffset;
261
260
  this._buffer = newBuffer;
262
- this.view = new DataView(this._buffer.buffer, oldOffset);
261
+ this.view = new DataView(this._buffer.buffer, this._buffer.byteOffset, this._buffer.byteLength);
263
262
  }
264
263
  this.woffset += amount;
265
264
  return this.woffset - amount;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@dcl/ecs",
3
3
  "description": "Decentraland ECS",
4
- "version": "7.26.1-32844959441.commit-a2ccd0b",
4
+ "version": "7.26.1-32861215853.commit-9eb2738",
5
5
  "author": "DCL",
6
6
  "bugs": "https://github.com/decentraland/ecs/issues",
7
7
  "files": [
@@ -34,5 +34,5 @@
34
34
  "dependencies": {},
35
35
  "types": "./dist/index.d.ts",
36
36
  "typings": "./dist/index.d.ts",
37
- "commit": "a2ccd0b174e93b8f393aa4862e3aeac6e77d745a"
37
+ "commit": "9eb2738b7bed246e72cf7007c7c25ab12dc2076d"
38
38
  }