Commit 4bb9cc21 authored by Varun Sridharan's avatar Varun Sridharan

Update woocommerce-quick-donation.php

parent fa3b9052
...@@ -95,6 +95,7 @@ class WooCommerce_Quick_Donation { ...@@ -95,6 +95,7 @@ class WooCommerce_Quick_Donation {
public function check_donation_exists_cart(){ public function check_donation_exists_cart(){
global $woocommerce; global $woocommerce;
$found = false; $found = false;
if(is_null($woocommerce)){return $found;}
if(empty($woocommerce)) {return;} if(empty($woocommerce)) {return;}
if( sizeof($woocommerce->cart->get_cart()) > 0){ if( sizeof($woocommerce->cart->get_cart()) > 0){
foreach($woocommerce->cart->get_cart() as $cart_item_key=>$values){ foreach($woocommerce->cart->get_cart() as $cart_item_key=>$values){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment