X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/f46dfda018cac3aeaa549d678ad036d0cfff2e6d..c6a27f90a8e644ed00910aeddaff38c74b513032:/SL/Form.pm diff --git a/SL/Form.pm b/SL/Form.pm index ff7d0efa0..539cd9cb2 100644 --- a/SL/Form.pm +++ b/SL/Form.pm @@ -878,7 +878,7 @@ sub format_amount { # this is easy to confuse, so keep in mind: before this comment no s///, m//, concat or other strong ops on # $amount. after this comment no +,-,*,/,abs. it will only introduce subtle bugs. - $amount =~ s/0*$//; # cull trailing 0s + $amount =~ s/0*$// unless defined $places && $places == 0; # cull trailing 0s my @d = map { s/\d//g; reverse split // } my $tmp = $myconfig->{numberformat}; # get delim chars my @p = split(/\./, $amount); # split amount at decimal point