spool invoice to billco if no other destinations are set!
authorivan <ivan>
Wed, 2 Nov 2005 21:18:17 +0000 (21:18 +0000)
committerivan <ivan>
Wed, 2 Nov 2005 21:18:17 +0000 (21:18 +0000)
FS/FS/cust_bill.pm

index 478facc..0cfe5c9 100644 (file)
@@ -838,7 +838,8 @@ sub spool_csv {
   if ( $opt{'dest'} ) {
     my %invoicing_list = map { /^(POST|FAX)$/ or 'EMAIL' =~ /^(.*)$/; $1 => 1 }
                              $self->cust_main->invoicing_list;
-    return unless $invoicing_list{$opt{'dest'}};
+    return 'N/A' unless $invoicing_list{$opt{'dest'}}
+                     || ! keys %invoicing_list;
   }
 
   #create file(s)