@labdigital/commercetools-mock 2.16.0 → 2.16.1
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/README.md +9 -9
- package/dist/index.cjs +2 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/repositories/shopping-list.ts +2 -1
- package/src/services/shopping-list.test.ts +18 -1
package/dist/index.js
CHANGED
|
@@ -6253,7 +6253,7 @@ var ShoppingListRepository = class extends AbstractResourceRepository {
|
|
|
6253
6253
|
this._storage
|
|
6254
6254
|
)
|
|
6255
6255
|
};
|
|
6256
|
-
if (variantId) {
|
|
6256
|
+
if (productId && variantId) {
|
|
6257
6257
|
return lineItem;
|
|
6258
6258
|
}
|
|
6259
6259
|
if (sku) {
|
|
@@ -6272,6 +6272,7 @@ var ShoppingListRepository = class extends AbstractResourceRepository {
|
|
|
6272
6272
|
];
|
|
6273
6273
|
const variantId2 = allVariants.find((e) => e.sku === sku)?.id;
|
|
6274
6274
|
lineItem.variantId = variantId2;
|
|
6275
|
+
lineItem.productId = product.id;
|
|
6275
6276
|
return lineItem;
|
|
6276
6277
|
}
|
|
6277
6278
|
if (productId) {
|