Remove unused global. Closes #4694
This commit is contained in:
parent
437e8e35a0
commit
61a7fa93ef
|
@ -34,8 +34,6 @@ add_filter( 'woocommerce_add_to_cart_validation', 'wc_protected_product_add_to_c
|
|||
* @return void
|
||||
*/
|
||||
function wc_empty_cart() {
|
||||
global $woocommerce;
|
||||
|
||||
if ( ! isset( WC()->cart ) || WC()->cart == '' )
|
||||
WC()->cart = new WC_Cart();
|
||||
|
||||
|
@ -262,4 +260,4 @@ function wc_cart_totals_shipping_method_label( $method ) {
|
|||
}
|
||||
|
||||
return apply_filters( 'woocommerce_cart_shipping_method_full_label', $label, $method );
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue