[freeside-commits] branch FREESIDE_3_BRANCH updated. 28cb520f6273aa76b4735ce22215e2235501198c

Ivan Kohler ivan at freeside.biz
Wed Nov 28 13:17:54 PST 2018


The branch, FREESIDE_3_BRANCH has been updated
       via  28cb520f6273aa76b4735ce22215e2235501198c (commit)
      from  bcc11e8b99854452cdccd9406918c015bee784cb (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 28cb520f6273aa76b4735ce22215e2235501198c
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Wed Nov 28 13:17:53 2018 -0800

    fix error linking legacy services, RT#81818

diff --git a/FS/FS/cust_svc.pm b/FS/FS/cust_svc.pm
index e64862f9d..d4d8684ac 100644
--- a/FS/FS/cust_svc.pm
+++ b/FS/FS/cust_svc.pm
@@ -401,8 +401,10 @@ sub replace {
   #my $error = $new->SUPER::replace($old, @_);
   my $error = $new->SUPER::replace($old);
 
-  #trigger a relocate export on location changes
-  if ( $new->cust_pkg->locationnum != $old->cust_pkg->locationnum ) {
+  #trigger a relocate export on location changes (NENA2 and Northern 911 export)
+  my $old_pkg = $old->cust_pkg;
+  my $new_pkg = $new->cust_pkg;
+  if ( $old_pkg && $new_pkg && $new_pkg->locationnum != $old_pkg->locationnum ) {
     my $svc_x = $new->svc_x;
     if ( $svc_x->locationnum ) {
       if ( $svc_x->locationnum == $old->cust_pkg->locationnum ) {

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/cust_svc.pm | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)




More information about the freeside-commits mailing list