fix case-insensitive matching for coupon posts with uppercase chars

This commit is contained in:
Jim Greenleaf 2014-04-30 23:29:29 -04:00 committed by Mike Jolley
parent 0a2b75db82
commit 3ea4e79b82
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;