forked from crowetic/commerce
Add optional chaining operator
This commit is contained in:
parent
2a843d7700
commit
cd829884f9
@ -28,7 +28,7 @@ interface Props {
|
|||||||
const ProductView: FC<Props> = ({ product }) => {
|
const ProductView: FC<Props> = ({ product }) => {
|
||||||
const addItem = useAddItem()
|
const addItem = useAddItem()
|
||||||
const { price } = usePrice({
|
const { price } = usePrice({
|
||||||
amount: product.prices?.price.value,
|
amount: product.prices?.price?.value,
|
||||||
baseAmount: product.prices?.retailPrice?.value,
|
baseAmount: product.prices?.retailPrice?.value,
|
||||||
currencyCode: product.prices?.price?.currencyCode!,
|
currencyCode: product.prices?.price?.currencyCode!,
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user