@azrico/webobject 1.5.47 → 1.5.48

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.
@@ -1508,13 +1508,16 @@ var SimpleObject = exports.SimpleObject = /*#__PURE__*/function (_MapableObject)
1508
1508
  return s === false;
1509
1509
  }) == null;
1510
1510
  }
1511
- /* ----------------------------- check products ----------------------------- */
1512
- if (result_object.products) {
1511
+ /* ----------------------------- check products/variations ----------------------------- */
1512
+ var varKeys = ["products", "variations"];
1513
+ for (var _i = 0, _varKeys = varKeys; _i < _varKeys.length; _i++) {
1514
+ var vk = _varKeys[_i];
1515
+ if (!(vk in result_object)) continue;
1513
1516
  /**
1514
1517
  * if one product is not valid the result is not valid
1515
1518
  * but if all products are valid we still need to check the object itself
1516
1519
  */
1517
- if (!this.isResultValid(result_object.products, depth + 1)) return false;
1520
+ if (!this.isResultValid(result_object[vk], depth + 1)) return false;
1518
1521
  }
1519
1522
  if (result_object.order) {
1520
1523
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@azrico/webobject",
3
- "version": "1.5.47",
3
+ "version": "1.5.48",
4
4
  "description": "Stateful object",
5
5
  "author": "Azrideus",
6
6
  "license": "MIT",