diff --git a/readme.txt b/readme.txt index 754477bb3bf..fb97b163917 100644 --- a/readme.txt +++ b/readme.txt @@ -159,6 +159,7 @@ Yes you can! Join in on our [GitHub repository](http://github.com/woothemes/wooc * Tweak - Swapped invoice and custom in paypal and added prefix (https://github.com/woothemes/woocommerce/issues/1149) * Tweak - Order page styling * Fix - has_file() handling for variations +* Fix - Hide if cart is empty option = 1.6.2 - 09/08/2012 = * Feature - Added google analytics event tracking for add to cart buttons (thanks to Max Rice) diff --git a/widgets/widget-cart.php b/widgets/widget-cart.php index 785e5bdbd95..617b5a43d31 100644 --- a/widgets/widget-cart.php +++ b/widgets/widget-cart.php @@ -35,7 +35,7 @@ class WooCommerce_Widget_Cart extends WP_Widget { /** @see WP_Widget */ function widget( $args, $instance ) { global $woocommerce; - + extract( $args ); if ( is_cart() || is_checkout() ) return; @@ -44,11 +44,11 @@ class WooCommerce_Widget_Cart extends WP_Widget { $hide_if_empty = empty( $instance['hide_if_empty'] ) ? 0 : 1; echo $before_widget; - - if ( $title ) + + if ( $title ) echo $before_title . $title . $after_title; - - $woocommerce->mfunc_wrapper( 'woocommerce_mini_cart()', 'woocommerce_mini_cart', array( $hide_if_empty ? 'hide_cart_widget_if_empty' : '' ) ); + + $woocommerce->mfunc_wrapper( 'woocommerce_mini_cart()', 'woocommerce_mini_cart', array( 'list_class' => $hide_if_empty ? 'hide_cart_widget_if_empty' : '' ) ); echo $after_widget;