Closed (fixed)
Project:
Commerce Core
Version:
7.x-1.x-dev
Component:
Cart
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
22 Oct 2012 at 18:01 UTC
Updated:
23 Apr 2013 at 19:30 UTC
Jump to comment: Most recent file
Comments
Comment #1
bojanz commentedI think this only appears on old (pre 1.4) carts (if you retry with a new cart, the notice won't be there).
Comment #2
jday commentedI get the error on product pages.
Comment #3
vasikeIt seems it's about the display "Add to cart form" formatter that haven't the new setting 'show_single_product_attributes' (Show attribute widgets even if the Add to Cart form only represents one product.) set. so probably for all product displays OLD Displays that use this formatter and are not re-set (resaved).
Probably a similar error takes place also on Manage Displays pages
Solutions
1. Just resave the Product Display Content Type "Displays", that uses "Add to cart form" formatter for product.
2. the patch attached.
Comment #5
jday commentedI re-saved my product display "displays" and the error is gone, thanks.
Comment #6
rszrama commentedYep, I should've caught that when the new setting was added. This is why I prefer !empty() checks on boolean values in arrays instead of just assuming there's going to be a boolean value there. It combines the "is it set? is it not FALSE?" into a single quick statement and ensure the result is a boolean to boot.
Commit: http://drupalcode.org/project/commerce.git/commitdiff/bc7367a