Change duplicate coupon error code

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

View File

@ -216,7 +216,7 @@ class WC_API_Coupons extends WC_API_Resource {
", wc_clean( $data['code'] ) ) );
if ( $coupon_found ) {
return new WP_Error( 'woocommerce_api_invalid_coupon_code', __( 'The coupon code already exists' ), array( 'status' => 400 ) );
return new WP_Error( 'woocommerce_api_coupon_code_already_exists', __( 'The coupon code already exists' ), array( 'status' => 400 ) );
}
$defaults = array(