X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/981b670e29449b7ebffe6c910439a05e6613ec6b..efc260398df0f3a9ecd36415b277c43e0c97fea7:/SL/Form.pm diff --git a/SL/Form.pm b/SL/Form.pm index a0fa96a2c..c5a30bf78 100644 --- a/SL/Form.pm +++ b/SL/Form.pm @@ -519,6 +519,12 @@ sub format_amount { $main::lxdebug->enter_sub(); my ($self, $myconfig, $amount, $places, $dash) = @_; + + #Workaround for $format_amount calls without $places + if (!defined $places){ + (my $dec) = ($amount =~ /\.(\d+)/); + $places = length $dec; + } if ($places =~ /\d/) { $amount = $self->round_amount($amount, $places);