[freeside-commits] freeside/FS/FS cust_main.pm,1.560,1.561
Mark Wells
mark at wavetail.420.am
Tue Oct 12 14:01:30 PDT 2010
Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail.420.am:/tmp/cvs-serv31168/FS/FS
Modified Files:
cust_main.pm
Log Message:
fix some noisy warnings
Index: cust_main.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_main.pm,v
retrieving revision 1.560
retrieving revision 1.561
diff -u -w -d -r1.560 -r1.561
--- cust_main.pm 12 Oct 2010 00:12:02 -0000 1.560
+++ cust_main.pm 12 Oct 2010 21:01:28 -0000 1.561
@@ -2270,7 +2270,7 @@
AND _date <= $time
";
- sprintf( "%.2f", $self->scalar_sql($sql) );
+ sprintf( "%.2f", $self->scalar_sql($sql) || 0 );
}
@@ -2350,8 +2350,7 @@
WHERE custnum = $custnum
";
- #XXX fix harmless but loud: Argument "" isn't numeric in sprintf
- sprintf( "%.2f", $self->scalar_sql($sql) );
+ sprintf( "%.2f", $self->scalar_sql($sql) || 0 );
}
@@ -2389,8 +2388,7 @@
WHERE custnum = $custnum
";
- #XXX fix harmless but loud: Argument "" isn't numeric in sprintf
- sprintf( "%.2f", $self->scalar_sql($sql) );
+ sprintf( "%.2f", $self->scalar_sql($sql) || 0 );
}
@@ -2428,8 +2426,7 @@
WHERE custnum = $custnum
";
- #XXX fix harmless but loud: Argument "" isn't numeric in sprintf
- sprintf( "%.2f", $self->scalar_sql($sql) );
+ sprintf( "%.2f", $self->scalar_sql($sql) || 0 );
}
@@ -2487,7 +2484,7 @@
my $self = shift;
my $sql = 'SELECT SUM('. $self->balance_date_sql(@_).
') FROM cust_main WHERE custnum='. $self->custnum;
- sprintf( '%.2f', $self->scalar_sql($sql) );
+ sprintf( '%.2f', $self->scalar_sql($sql) || 0 );
}
=item balance_pkgnum PKGNUM
More information about the freeside-commits
mailing list