+
+ }
+
+ if ( $opt{b} ) {
+ print "\n\tBilling" unless $opt{q};
+ my $error = $cust_main->bill('time'=>$now);
+ warn "Error billing, customer #" . $cust_main->custnum .
+ ":" . $error if $error;
+ }
+
+ if ( $opt{y} ) {
+ print "\n\tApplying outstanding payments and credits" unless $opt{q};
+ $cust_main->apply_payments;
+ $cust_main->apply_credits;
+ }