Skip to content

Commit 7b1dc36

Browse files
committed
Update functions.tsx
1 parent ee68b76 commit 7b1dc36

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

src/utils/functions/functions.tsx

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import { v4 as uuidv4 } from 'uuid';
44

5-
import { RootObject, Product } from '@/stores/cart';
5+
import { RootObject } from '@/stores/cart';
66

77
import { ChangeEvent } from 'react';
88
import { IVariationNodes } from '@/components/Product/AddToCart.component';
@@ -182,7 +182,7 @@ export const getFormattedCart = (data: IFormattedCartProps) => {
182182
sourceUrl: process.env.NEXT_PUBLIC_PLACEHOLDER_SMALL_IMAGE_URL,
183183
srcSet: process.env.NEXT_PUBLIC_PLACEHOLDER_SMALL_IMAGE_URL,
184184
title: givenProduct.name,
185-
}
185+
},
186186
};
187187
});
188188
formattedCart.totalProductsCount = totalProductsCount;
@@ -279,10 +279,12 @@ export const handleQuantityChange = (
279279
variables: {
280280
input: {
281281
clientMutationId: uuidv4(),
282-
items: [{
283-
key: cartKey,
284-
quantity: newQty
285-
}],
282+
items: [
283+
{
284+
key: cartKey,
285+
quantity: newQty,
286+
},
287+
],
286288
},
287289
},
288290
});

0 commit comments

Comments
 (0)