From: Mark Wells Date: Mon, 5 Nov 2012 22:09:50 +0000 (-0800) Subject: fix ICS invoice spooling when service records are missing, #17620 X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=commitdiff_plain;h=25d9baac5e5ef0be9801b54f8365fc40b639a546 fix ICS invoice spooling when service records are missing, #17620 --- diff --git a/FS/FS/cust_bill.pm b/FS/FS/cust_bill.pm index dad54348e..128aaf7e0 100644 --- a/FS/FS/cust_bill.pm +++ b/FS/FS/cust_bill.pm @@ -2248,11 +2248,13 @@ sub print_csv { $part_svc_class->classname : ''; } - + + my $svc_x = $cust_svc->svc_x or + warn "missing svc_x record for svc#".$cust_svc->svcnum."\n"; push @details, sprintf('01%-9s%-20s%-47s', $cust_svc->svcnum, $svc_class{$svcpart}, - $cust_svc->svc_x->label, + ($svc_x ? $svc_x->label : ''), ); } #foreach $cust_svc } #if $cust_pkg