A Database Error Occurred

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'AND ci.cart_items_deleted_at IS NULL' at line 7

SELECT ci.*,p.product_name,v.variant_final_price as product_price,v.variant_size,v.variant_type,p.slug,(SELECT product_image_name FROM `product_images` WHERE product_images.product_id=p.product_id limit 1) as img FROM `cart_items` ci LEFT JOIN `cart` c ON(c.cart_id=ci.cart_id) LEFT JOIN `customer` cu ON(cu.customer_id=c.customer_id) LEFT JOIN `product` p ON(p.product_id=ci.product_id) LEFT JOIN `variant` v ON(v.variant_id=ci.variant_id) WHERE c.customer_id= AND ci.cart_items_deleted_at IS NULL

Filename: controllers/Checkout.php

Line Number: 20