Index: uc_attribute/uc_attribute.ca.inc =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/ubercart/uc_attribute/uc_attribute.ca.inc,v retrieving revision 1.1.2.2 diff -u -p -r1.1.2.2 uc_attribute.ca.inc --- uc_attribute/uc_attribute.ca.inc 21 Jul 2009 14:37:21 -0000 1.1.2.2 +++ uc_attribute/uc_attribute.ca.inc 27 Feb 2010 14:16:09 -0000 @@ -33,8 +33,6 @@ function uc_attribute_ca_condition() { function uc_attribute_condition_ordered_product_option($order, $settings) { $result = FALSE; - $match = unserialize($settings['attribute_option']); - foreach ($order->products as $product) { if (!isset($product->data['attributes'])) { continue; @@ -42,8 +40,8 @@ function uc_attribute_condition_ordered_ $attributes = $product->data['attributes']; - // Once the order is made, the attribute data is changed to just the names. - // If we can't find it by ID, check the names. + // Once the order is made, the attribute data is changed to just the labels. + // If we can't find it by ID, check the labels. if (is_int(key($attributes))) { if (in_array($settings['attribute_option'], $attributes)) { $result = TRUE; @@ -59,7 +57,9 @@ function uc_attribute_condition_ordered_ } if ($attribute) { - if (isset($attributes[$attribute->name]) && $attributes[$attribute->name] == $option->name) { + $attribute_label = $attributes[$attribute->label]; + $attribute_label = $attribute_label[0]; + if (isset($attribute_label) && $attribute_label == $option->name) { $result = TRUE; break; }