For now, comment out 2 of the messages at the bottom of the file around lines 1847 - 1873:
/includes/classes/shopping_cart.php
The routine is used 2 ways and is passing the messages when it should not ...
PHP Code:
function adjust_quantity($check_qty, $products, $message=false) {
global $messageStack;
$old_quantity = $check_qty;
if (QUANTITY_DECIMALS != 0) {
// $new_qty = round($new_qty, QUANTITY_DECIMALS);
$fix_qty = $check_qty;
switch (true) {
case (!strstr($fix_qty, '.')):
$new_qty = $fix_qty;
// $messageStack->add_session('shopping_cart', ERROR_QUANTITY_ADJUSTED . ' - ' . zen_get_products_name($products) . ' - ' . $old_quantity . ' => ' . $new_qty, 'caution');
break;
default:
$new_qty = preg_replace('/[0]+$/','', $check_qty);
// $messageStack->add_session('shopping_cart', ERROR_QUANTITY_ADJUSTED . ' - ' . zen_get_products_name($products) . ' - ' . $old_quantity . ' => ' . $new_qty, 'caution');
break;
}
} else {
if ($check_qty != round($check_qty, QUANTITY_DECIMALS)) {
$new_qty = round($check_qty, QUANTITY_DECIMALS);
$messageStack->add_session('shopping_cart', ERROR_QUANTITY_ADJUSTED . ' - ' . zen_get_products_name($products) . ' - ' . $old_quantity . ' => ' . $new_qty, 'caution');
} else {
$new_qty = $check_qty;
}
}
return $new_qty;
}
Bookmarks