[freeside-commits] freeside/FS/bin freeside-torrus-srvderive, 1.62, 1.63
Ivan,,,
ivan at wavetail.420.am
Tue Sep 27 11:38:17 PDT 2011
Update of /home/cvs/cvsroot/freeside/FS/bin
In directory wavetail.420.am:/tmp/cvs-serv18652
Modified Files:
freeside-torrus-srvderive
Log Message:
fix "Can' tuse an undefined value as an ARRAY reference" error for new virtual ports, RT#14594
Index: freeside-torrus-srvderive
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/bin/freeside-torrus-srvderive,v
retrieving revision 1.62
retrieving revision 1.63
diff -u -w -d -r1.62 -r1.63
--- freeside-torrus-srvderive 23 Sep 2011 23:45:26 -0000 1.62
+++ freeside-torrus-srvderive 27 Sep 2011 18:38:14 -0000 1.63
@@ -82,7 +82,8 @@
ORDER BY srv_date LIMIT 1";
my $dsth = dbh->prepare($dsql) or die $DBI::errstr;
$dsth->execute or die $dsth->errstr;
- my $date = $dsth->fetchrow_arrayref->[0];
+ my $row = $dsth->fetchrow_arrayref;
+ my $date = (defined($row) && ref($row)) ? $row->[0] : '';
if ( $date ) {
warn "found initial last_srv_date of $date; updating $serviceid\n"
if $DEBUG;
More information about the freeside-commits
mailing list