Socket
Socket
Sign inDemoInstall

@nuskin/ns-product-lib

Package Overview
Dependencies
Maintainers
5
Versions
491
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@nuskin/ns-product-lib - npm Package Compare versions

Comparing version 2.17.0-cx24-5822.7 to 2.17.0-cx24-5822.8

2

package.json
{
"name": "@nuskin/ns-product-lib",
"version": "2.17.0-cx24-5822.7",
"version": "2.17.0-cx24-5822.8",
"description": "This project contains shared Product models and code between the backend and frontend.",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -148,8 +148,12 @@ const axios = require('axios').default;

const productsData = [];
if (products?.data?.productsById?.products?.length) {
if (products &&
products.data &&
products.data.productsById &&
products.data.productsById.products &&
products.data.productsById.products.length) {
skus.forEach((sku)=>{
const matchedProducts = products.data.productsById.products.filter((product)=>{
let matched = false;
if(product?.id) {matched = product.id === sku;}
if(product?.variants?.length){
if(product.id) {matched = product.id === sku;}
if(product.variants.length){
product.variants.forEach((variant)=>{

@@ -156,0 +160,0 @@ matched |= variant.sku === sku;

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc