diff --git a/src/WooCommerce/Checkout.php b/src/WooCommerce/Checkout.php index 0cbe132..c51ece2 100644 --- a/src/WooCommerce/Checkout.php +++ b/src/WooCommerce/Checkout.php @@ -93,7 +93,7 @@ public function apply_coupon_via_url() { return; } - WC()->cart->add_discount( wc_clean( $coupon_code ) ); + WC()->cart->add_discount( wc_sanitize_coupon_code( $coupon_code ) ); } /**