Fix typing with casts

This commit is contained in:
MDW 2024-03-21 22:12:37 +01:00
parent b2a3985fb3
commit 6eeab82dd4
No known key found for this signature in database

View file

@ -84,7 +84,7 @@ if ($action == 'confirm_split' && GETPOST("confirm", "alpha") == 'yes' && $permi
$error++;
setEventMessages($langs->trans("ErrorFailedToLoadDiscount"), null, 'errors');
}
if (!$error && price2num($amount_ttc_1 + $amount_ttc_2) != $discount->amount_ttc) {
if (!$error && price2num((float) $amount_ttc_1 + (float) $amount_ttc_2) != $discount->amount_ttc) {
$error++;
setEventMessages($langs->trans("TotalOfTwoDiscountMustEqualsOriginal"), null, 'errors');
}