@nuskin/ns-product-lib 2.21.3-it-31008.2 → 2.21.3

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/product.js +1 -5
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nuskin/ns-product-lib",
3
- "version": "2.21.3-it-31008.2",
3
+ "version": "2.21.3",
4
4
  "description": "This project contains shared Product models and code between the backend and frontend.",
5
5
  "main": "src/index.js",
6
6
  "scripts": {
package/src/product.js CHANGED
@@ -450,10 +450,6 @@ const Product = function (productData) {
450
450
  return this.custTypes.includes("30");
451
451
  };
452
452
 
453
- this.isBase = function () {
454
- return this.variantSkus().length > 0;
455
- };
456
-
457
453
  this.isVariant = function () {
458
454
  return this.baseSku.length > 0 && this.variantSkus().length === 0;
459
455
  };
@@ -579,7 +575,7 @@ const Product = function (productData) {
579
575
  this.thumbnail = ProductUtils.applyBaseUrl(this.thumbnail, baseUrl);
580
576
  this.fullImage = ProductUtils.applyBaseUrl(this.fullImage, baseUrl);
581
577
 
582
- if (this.isBase()) {
578
+ if (this.variantSkus().length > 0) {
583
579
  for (const variantSku in this.variants) {
584
580
  const variant = this.variants[variantSku];
585
581
  variant.setBaseUrl(baseUrl);