Merge pull request #5402 from aMoniker/master

fix case-insensitive matching for coupon posts with uppercase chars
This commit is contained in:
Mike Jolley 2014-05-01 12:23:04 +01:00
commit c9378cf092
1 changed files with 1 additions and 1 deletions

View File

@ -138,7 +138,7 @@ class WC_Coupon {
$coupon = get_post( $coupon_id ); $coupon = get_post( $coupon_id );
$this->post_title = apply_filters( 'woocommerce_coupon_code', $coupon->post_title ); $this->post_title = apply_filters( 'woocommerce_coupon_code', $coupon->post_title );
if ( empty( $coupon ) || $this->code !== $coupon->post_title ) if ( empty( $coupon ) || $this->code !== $this->post_title )
return; return;
$this->id = $coupon->ID; $this->id = $coupon->ID;