Skip to content

Commit

Permalink
Wrong calculation for product items #178
Browse files Browse the repository at this point in the history
  • Loading branch information
perminder-klair committed Jun 18, 2019
1 parent 56681bc commit e5ce3c9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/pages/Dashboard/components/ProductItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ class ProductItem extends React.Component {
const { price } = this.state;
const { product, currency } = this.props;

if (!product.priceCurrency) {
return this.setState({ price });
}
if (
product.priceCurrency.length === 0 ||
product.priceCurrency === currency
Expand Down

0 comments on commit e5ce3c9

Please sign in to comment.