Modify duplicate coupon error code

This commit is contained in:
Gerhard 2014-03-05 09:28:59 +02:00
parent f2f7e09143
commit db2de990e7
1 changed files with 2 additions and 0 deletions

View File

@ -241,6 +241,8 @@ class WC_API_Coupons extends WC_API_Resource {
$coupon_data = wp_parse_args( $data, $defaults );
$coupon_code =
$new_coupon = array(
'post_title' => wc_clean( $coupon_data['code'] ),
'post_content' => '',