[Koha-patches] [PATCH] Bug 4192: Fixes warnings generated by opac-account.pl.
Garry Collum
gcollum at gmail.com
Mon Feb 15 23:44:47 CET 2010
---
opac/opac-account.pl | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/opac/opac-account.pl b/opac/opac-account.pl
index 43a1e0c..22d83b8 100755
--- a/opac/opac-account.pl
+++ b/opac/opac-account.pl
@@ -51,12 +51,12 @@ my ( $total , $accts, $numaccts) = GetMemberAccountRecords( $borrowernumber );
for ( my $i = 0 ; $i < $numaccts ; $i++ ) {
$accts->[$i]{'date'} = format_date( $accts->[$i]{'date'} );
- $accts->[$i]{'amount'} = sprintf( "%.2f", $accts->[$i]{'amount'} );
+ $accts->[$i]{'amount'} = sprintf( "%.2f", $accts->[$i]{'amount'} || '0.00');
if ( $accts->[$i]{'amount'} >= 0 ) {
$accts->[$i]{'amountcredit'} = 1;
}
$accts->[$i]{'amountoutstanding'} =
- sprintf( "%.2f", $accts->[$i]{'amountoutstanding'} );
+ sprintf( "%.2f", $accts->[$i]{'amountoutstanding'} || '0.00' );
if ( $accts->[$i]{'amountoutstanding'} >= 0 ) {
$accts->[$i]{'amountoutstandingcredit'} = 1;
}
--
1.5.6.5
More information about the Koha-patches
mailing list