diff --git a/src/User/components/Products/ProductDetails.jsx b/src/User/components/Products/ProductDetails.jsx index 3ecba7e1c..a6d796638 100644 --- a/src/User/components/Products/ProductDetails.jsx +++ b/src/User/components/Products/ProductDetails.jsx @@ -263,8 +263,8 @@ const ProductPage = () => { try { const response = await axios.get(`https://dummyjson.com/products/${productId}`); const requiredProduct = response.data; - console.log(response.data) requiredProduct.newPrice = getNewPrice(requiredProduct.discountPercentage, requiredProduct.price) + requiredProduct.image = requiredProduct.images[0] || requiredProduct.thumbnail setProduct(requiredProduct); } catch (error) { console.error("Axios error:", error); diff --git a/src/User/pages/Order/Wishlist.jsx b/src/User/pages/Order/Wishlist.jsx index 3bff5e537..5fa9fcf46 100644 --- a/src/User/pages/Order/Wishlist.jsx +++ b/src/User/pages/Order/Wishlist.jsx @@ -35,7 +35,7 @@ const WishlistItem = ({ product, onUpdate, onAddToCart, isExistsInTheCart }) => style={{ border: "1px solid black" }}>