Skip to content

Commit 10a297c

Browse files
authored
Merge pull request #359 from w3bdesign/develop
Remove nested ternary
2 parents 355b7d5 + 8a12094 commit 10a297c

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

components/Checkout/CheckoutForm.component.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import Billing from './Billing.component';
55
import OrderDetails from './OrderDetails.component';
66
import MobileOrderDetails from './MobileOrderDetails.component';
77
import LoadingSpinner from '../LoadingSpinner/LoadingSpinner.component';
8-
//import Payment from './Payment.component';
8+
// TODO Add more payment methods
99

1010
import { GET_CART } from 'utils/gql/GQL_QUERIES';
1111
import { CHECKOUT_MUTATION } from 'utils/gql/GQL_MUTATIONS';

components/Product/SingleProduct.component.jsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,14 +43,15 @@ const SingleProduct = ({ product }) => {
4343
) : (
4444
<div className="container flex flex-wrap items-center pt-4 pb-12 mx-auto ">
4545
<div className="grid grid-cols-1 gap-4 mt-16 lg:grid-cols-2 xl:grid-cols-2 md:grid-cols-2 sm:grid-cols-2">
46-
{image ? (
46+
{image && (
4747
<img
4848
id="product-image"
4949
className="h-auto p-8 transition duration-500 ease-in-out transform xl:p-2 md:p-2 lg:p-2 hover:grow hover:shadow-lg hover:scale-105"
5050
alt={name}
5151
src={image.sourceUrl}
5252
/>
53-
) : (
53+
)}
54+
{!image && (
5455
<img
5556
id="product-image"
5657
className="h-auto p-8 transition duration-500 ease-in-out transform xl:p-2 md:p-2 lg:p-2 hover:grow hover:shadow-lg hover:scale-105"

0 commit comments

Comments
 (0)