- Fixed: Return response for numeric thanks to @campusboy87
- Fixed: Fatal error for adding and updating items when validating the callback
is_numeric
. - Issue #30
- Fixed: Syntax error for including cart controller for sites running versions of PHP lower than 7. Thanks to @Mr-AjayM for another contribution.
- Fixed: Validation of
cart_item_key
when removing, restoring or updating an item. Item keys starting with a letter were returning false. Reported by @Janie20. - Tested up to WooCommerce v3.3.5 and up to WordPress v4.9.5
- Fixed: Invalid Argument Error should the cart be empty. Now returns "Cart is empty" properly. Thanks to @Mr-AjayM for the contribution.
- Added: Fetch current cart item data before it is updated.
- Added: New endpoint to restore, remove and update items in cart due to a conflict that prevented from registering the route.
- Corrected: Fetching cart item key as integer to a clean string.
- Corrected: Had response messages for updating quantity backwards. Oops!
- Improved: Made sure it returns a response if the cart is empty.
- Enhanced: Added a check to see if the cart has any items before calculating totals.
- Initial version.