when un-cancelling a package, errors re-provisioning services are not fatal, RT#17518
authorIvan Kohler <ivan@freeside.biz>
Thu, 3 May 2012 20:57:54 +0000 (13:57 -0700)
committerIvan Kohler <ivan@freeside.biz>
Thu, 3 May 2012 20:57:54 +0000 (13:57 -0700)
FS/FS/cust_pkg.pm

index 5ccdb35..1cca10b 100644 (file)
@@ -885,7 +885,9 @@ sub cancel_if_expired {
 locationnum, (other fields?).  Attempts to re-provision cancelled services
 using history information (errors at this stage are not fatal).
 
-cust_pkg: pass a scalar reference, will be filled in with
+cust_pkg: pass a scalar reference, will be filled in with the new cust_pkg object
+
+svc_fatal: service provisioning errors are fatal
 
 svc_errors: pass an array reference, will be filled in with any provisioning errors
 
@@ -968,7 +970,7 @@ sub uncancel {
     }
 
     my $svc_error = $svc_x->insert;
-    if ( $svc_error ) { #&& $options{svc_fatal} ) {
+    if ( $svc_error && $options{svc_fatal} ) {
       $dbh->rollback if $oldAutoCommit;
       return $error;
     }