From db5e2572f6553899b8508092bb5158bec9e7f058 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Thu, 27 Apr 2017 13:01:52 +0100 Subject: [PATCH] clean up --- includes/abstracts/abstract-wc-product.php | 2 +- includes/class-wc-product-variable.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/includes/abstracts/abstract-wc-product.php b/includes/abstracts/abstract-wc-product.php index 3c9b3d6dc96..9cf9e9461c1 100644 --- a/includes/abstracts/abstract-wc-product.php +++ b/includes/abstracts/abstract-wc-product.php @@ -1644,7 +1644,7 @@ class WC_Product extends WC_Abstract_Legacy_Product { public function get_price_html( $deprecated = '' ) { if ( '' === $this->get_price() ) { $price = apply_filters( 'woocommerce_empty_price_html', '', $this ); - } else if ( $this->is_on_sale() ) { + } elseif ( $this->is_on_sale() ) { $price = wc_format_sale_price( wc_get_price_to_display( $this, array( 'price' => $this->get_regular_price() ) ), wc_get_price_to_display( $this ) ) . $this->get_price_suffix(); } else { $price = wc_price( wc_get_price_to_display( $this ) ) . $this->get_price_suffix(); diff --git a/includes/class-wc-product-variable.php b/includes/class-wc-product-variable.php index 1d14e4478de..429325d1d5c 100644 --- a/includes/class-wc-product-variable.php +++ b/includes/class-wc-product-variable.php @@ -148,7 +148,7 @@ class WC_Product_Variable extends WC_Product { $price = apply_filters( 'woocommerce_variable_price_html', wc_format_sale_price( wc_price( $max_reg_price ), wc_price( $min_price ) ) . $this->get_price_suffix(), $this ); } else { $price = apply_filters( 'woocommerce_variable_price_html', wc_price( $min_price ) . $this->get_price_suffix(), $this ); - } + } } return apply_filters( 'woocommerce_get_price_html', $price, $this );