Skip to content

Commit

Permalink
Remove strtolower from WooCommerce order status
Browse files Browse the repository at this point in the history
  • Loading branch information
Luke Carbis committed Jul 27, 2016
1 parent ed02eda commit 4b46c55
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions connectors/class-connector-woocommerce.php
Original file line number Diff line number Diff line change
Expand Up @@ -422,13 +422,13 @@ public function callback_woocommerce_order_status_changed( $order_id, $old, $new
}

if ( version_compare( $this->plugin_version, '2.2', '>=' ) ) {
$old_status_name = strtolower( wc_get_order_status_name( $old ) );
$new_status_name = strtolower( wc_get_order_status_name( $new ) );
$old_status_name = wc_get_order_status_name( $old );
$new_status_name = wc_get_order_status_name( $new );
} else {
$old_status = wp_stream_is_vip() ? wpcom_vip_get_term_by( 'slug', $old, 'shop_order_status' ) : get_term_by( 'slug', $old, 'shop_order_status' );
$new_status = wp_stream_is_vip() ? wpcom_vip_get_term_by( 'slug', $new, 'shop_order_status' ) : get_term_by( 'slug', $new, 'shop_order_status' );
$new_status_name = strtolower( $new_status->name );
$old_status_name = strtolower( $old_status->name );
$new_status_name = $new_status->name;
$old_status_name = $old_status->name;
}

$message = esc_html_x(
Expand Down

0 comments on commit 4b46c55

Please sign in to comment.