how to check if cart is empty woocommerce code example
Example: woocommerce check if cart is not empty
if ( WC()->cart->get_cart_contents_count() == 0 ) {
// Do something fun
}
if ( WC()->cart->get_cart_contents_count() == 0 ) {
// Do something fun
}