@colyseus/schema 3.0.33 → 3.0.34

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.
@@ -4610,7 +4610,8 @@ function getDecoderStateCallbacks(decoder) {
4610
4610
  }
4611
4611
  }
4612
4612
  }
4613
- else if ((change.op & exports.OPERATION.ADD) === exports.OPERATION.ADD && change.previousValue === undefined) {
4613
+ else if ((change.op & exports.OPERATION.ADD) === exports.OPERATION.ADD &&
4614
+ change.previousValue !== change.value) {
4614
4615
  // triger onAdd
4615
4616
  const addCallbacks = $callbacks[exports.OPERATION.ADD];
4616
4617
  for (let i = addCallbacks?.length - 1; i >= 0; i--) {