Commit Graph

6 Commits

Author SHA1 Message Date
claudiulodro c08140a293 Formatting 2017-05-25 14:45:36 -07:00
claudiulodro e00d7b7c55 File metadata by id 2017-05-25 14:43:36 -07:00
Claudio Sanches f1dab3fdce Fixed coding standards 2017-03-21 12:38:35 -03:00
Claudiu Lodromanean c0a01a1fe4 Dont set empty strings as tax totals 2017-03-20 15:14:41 -07:00
Claudio Sanches 59c2849736 Changed version 2.7 to 3.0 2017-03-15 13:36:53 -03:00
Justin Shreve 9724b67ab8 Fix order item meta functions cache busting.
The cache busting currently in `wc_add_order_item_meta`, `wc_update_order_item_meta`, and `wc_delete_order_item_meta` doesn't actually bust anything. The cache line looks like it is from 2.6. The relevent cache to bust is actually in the `order-items` group and has a different key/prefix.
This bug allows your meta to get out of sync if you use these functions and then try to access a value from a CRUD object.

You can see this in the `test_wc_order_item_meta_functions` test I've added. If you keep your `wc-order-item-functions.php` as is, the asserts against `$item->get_meta` will fail.

To test:
* `phpunit --filter=test_wc_order_item_meta_functions`.
* Try before applying the `wc-order-item-functions.php` changes and after.
2017-03-09 13:36:23 -08:00