woothemes/woocommerce — Issue #781: cart_contents_count and some other calculated totals returns 0 when there is items in cart
Author: watabekensan
Created: 2012-03-10 07:38:20+00:00
State: open

Some precalculated totals variables like cart_contents_count and carts_contents_total and subtotal, doesnt update from the session after user logs in and persistent cart handler puts the cart from the db in the session.

scenario: log in, add items to cart, cart_contents_count reports proper count, log out, delete items, log back in, items are in cart from database/persisten cart, but cart_contents_count is 0, it will report proper count after adding more items. same with subtotal, etc...

(note when running functions like get_cart_subtotal instead, it will work and return proper number)