**What** - Adjust reservations correctly according to the following heuristic: adjustment by addition: (i.e. positive quantity adjustment passed to the adjustment method) - if a reservation for the line-item in the location exists add quantity to that - if not create a new reservation adjustment by subtraction: - if a reservation with the exact quantity exists, delete it and return - if a reservation with a greater quantity exists, subtract from it and return - otherwise delete from reservations until a reservation with greater quantity than the remaining is found and adjust that with the remaining quantity OR there are no more reservations Fixes CORE-1247
81 B
81 B
@medusajs/medusa-js
| @medusajs/medusa-js |
|---|
| patch |
Fix(medusa): Adjust reservations correctly