File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed
Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -112,14 +112,13 @@ export const getUpdatedProducts = (
112112 ) ;
113113
114114 return updatedProducts ;
115- } else {
116- // If product not found push the new product to the existing product array.
117- let productPrice = getFloatVal ( product . price ) ;
118- const newProduct = createNewProduct ( product , productPrice , qtyToBeAdded ) ;
119- existingProductsInCart . push ( newProduct ) ;
120-
121- return existingProductsInCart ;
122115 }
116+ // If product not found push the new product to the existing product array.
117+ let productPrice = getFloatVal ( product . price ) ;
118+ const newProduct = createNewProduct ( product , productPrice , qtyToBeAdded ) ;
119+ existingProductsInCart . push ( newProduct ) ;
120+
121+ return existingProductsInCart ;
123122} ;
124123
125124/**
You can’t perform that action at this time.
0 commit comments