Price Breaks Are Broken

Description

Price breaks show up but disappear when the item is added to the cart, as well as not being honored at all.

This was fixed in the bug 1132 (http://bugtrack.oscmax.com/view.php?id=1132) where;
$no_of_pricebreaks = (isset($price_break_array) ? count($price_breaks_array) : 0);
Was changed to;
$no_of_pricebreaks = count($price_breaks_array);

But in 2.5.2 the code has changed to;
if(isset($price_break_array)) {
$no_of_pricebreaks = count($price_breaks_array);
} else {
$no_of_pricebreaks = 0;
}

There is no need to check if $price_break_array is set or not as count returns 0 if the array is not set anyway.
(see http://www.php.net/manual/en/function.count.php for details)

Environment

None

Steps to reproduce

None

Assignee

Giles Marshall

Reporter

Scott Murphy

Labels

None

Severity

Major

Components

Fix versions

Affects versions

Priority

Configure