woocommerce/includes/rest-api/Controllers
Nestor Soriano 2b8cac7cf2 Fix the REST API entry point to add coupons to an order.
- Check input (no 'id', has 'code') and throw an error if needed
  before removing the existing coupons, so an invalid input
  won't cause the loss of these existing coupons.
- Also, check that the coupon is actually valid as part of the
  input check.
- Cache the coupon objects that are created during the input check,
  and apply them directly.
- Don't check if 'coupon_lines' is an array and contains arrays,
  that's already done by the REST API engine by looking at the schema.
- Adjust unit tests.
2021-03-24 15:19:34 +01:00
..
Version1 Fix taxes endpoint not returning multiple postcodes/cities 2021-03-15 22:16:36 +02:00
Version2 Merge pull request #29345 from woocommerce/hw/low-stock-threshold-for-variations 2021-03-17 08:59:32 +01:00
Version3 Fix the REST API entry point to add coupons to an order. 2021-03-24 15:19:34 +01:00