Skip to content

Commit

Permalink
♻️ chore: remove unused hooks/vars
Browse files Browse the repository at this point in the history
  • Loading branch information
StefanoSaffran committed Sep 22, 2020
1 parent b9ab703 commit aa5d608
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/hooks/cart.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ const CartProvider: React.FC = ({ children }) => {

const getTotal = useCallback(() => {
return products.reduce((total, nextProduct) => {
const [_, value] = nextProduct.price.split(' ');
const [, value] = nextProduct.price.split(' ');
const subtotal = nextProduct.quantity * Number(value.replace(',', '.'));
return (total += subtotal);
}, 0);
Expand Down

0 comments on commit aa5d608

Please sign in to comment.