edit_coupon REST API look for type and not discount_type
This commit is contained in:
parent
fa6eb98535
commit
a2ecd3885c
|
@ -288,7 +288,7 @@ class WC_API_Coupons extends WC_API_Resource {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( isset( $data['type'] ) ) {
|
if ( isset( $data['type'] ) ) {
|
||||||
update_post_meta( $id, 'discount_type', $data['discount_type'] );
|
update_post_meta( $id, 'discount_type', $data['type'] );
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( isset( $data['amount'] ) ) {
|
if ( isset( $data['amount'] ) ) {
|
||||||
|
|
Loading…
Reference in New Issue