diff --git a/htdocs/accountancy/bookkeeping/card.php b/htdocs/accountancy/bookkeeping/card.php index 0767023eacf..593c71188e8 100644 --- a/htdocs/accountancy/bookkeeping/card.php +++ b/htdocs/accountancy/bookkeeping/card.php @@ -648,7 +648,10 @@ if ($action == 'create') print "\n"; } - if (price2num($total_debit) != price2num($total_credit)) + $total_debit = price2num($total_debit); + $total_credit = price2num($total_credit); + + if ($total_debit != $total_credit) { setEventMessages(null, array($langs->trans('MvtNotCorrectlyBalanced', $total_credit, $total_debit)), 'warnings'); }