Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Basket Serialisation #7245

Closed
kb6673 opened this issue Jan 30, 2015 · 1 comment
Closed

Basket Serialisation #7245

kb6673 opened this issue Jan 30, 2015 · 1 comment

Comments

@kb6673
Copy link

kb6673 commented Jan 30, 2015

We're running some external validation on basket contents.
(Using woocommerce_check_cart_items to check items against an ERP system)

In short, it reads the serialised basket contents from wp_options.option_value
Most of the baskets unserialize correctly, eg

{s:10:"product_id";i:8865; (Snippet)

However some baskets store the product_id as a string, however all product_ids are integers

{s:10:"product_id";s:4:"8525"(Snippet)

We're wondering whether this is a Woo, WP or PHP bug within the basket serialization.

@mikejolley
Copy link
Member

There is no type casting on product_id. Will make them consistent in 2.4.

@mikejolley mikejolley added this to the 2.4 (name undecided) milestone Feb 2, 2015
@mikejolley mikejolley modified the milestone: 2.4 (name undecided) Mar 24, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants