mirror of
https://github.com/KevinMidboe/planetposen.git
synced 2025-10-29 01:30:32 +00:00
Prevent double generating of new variations.
This commit is contained in:
@@ -27,8 +27,6 @@ const addNewVariationToProduct = async (req, res) => {
|
||||
console.log('id: ', productId);
|
||||
console.log('variation: ', variation);
|
||||
|
||||
const newVariation = await saveNewVariation(variation);
|
||||
|
||||
return saveNewVariation(variation)
|
||||
.then(newVariation => products.addVariationToProduct(newVariation, productId))
|
||||
.then(() => res.send('New relation added to product'))
|
||||
|
||||
Reference in New Issue
Block a user