@colyseus/schema 1.0.30 → 1.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.
- package/build/cjs/index.js +2 -2
- package/build/cjs/index.js.map +1 -1
- package/build/esm/index.mjs +2 -2
- package/build/esm/index.mjs.map +1 -1
- package/build/umd/index.js +2 -2
- package/lib/codegen/types.js +8 -1
- package/lib/codegen/types.js.map +1 -1
- package/lib/types/ArraySchema.js +2 -2
- package/lib/types/ArraySchema.js.map +1 -1
- package/package.json +1 -1
package/build/cjs/index.js
CHANGED
|
@@ -712,7 +712,7 @@ var ArraySchema = /** @class */ (function () {
|
|
|
712
712
|
* @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.
|
|
713
713
|
*/
|
|
714
714
|
ArraySchema.prototype.reduce = function (callbackfn, initialValue) {
|
|
715
|
-
return Array.from(this.$items.values())
|
|
715
|
+
return Array.prototype.reduce.apply(Array.from(this.$items.values()), arguments);
|
|
716
716
|
};
|
|
717
717
|
/**
|
|
718
718
|
* Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.
|
|
@@ -720,7 +720,7 @@ var ArraySchema = /** @class */ (function () {
|
|
|
720
720
|
* @param initialValue If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.
|
|
721
721
|
*/
|
|
722
722
|
ArraySchema.prototype.reduceRight = function (callbackfn, initialValue) {
|
|
723
|
-
return Array.from(this.$items.values())
|
|
723
|
+
return Array.prototype.reduceRight.apply(Array.from(this.$items.values()), arguments);
|
|
724
724
|
};
|
|
725
725
|
/**
|
|
726
726
|
* Returns the value of the first element in the array where predicate is true, and undefined
|