I found this simpler code to work better, but I could be missing something.


if (($new_qty > $add_max ) and $add_max != 0) {
$ adjust_max= 'true';
$new_qty = $add_max;