[freeside-commits] branch master updated. f034f0e044b27e34b9e4e2fc819825b21c693df5

Christopher Burger burgerc at freeside.biz
Wed Jan 23 08:18:55 PST 2019


The branch, master has been updated
       via  f034f0e044b27e34b9e4e2fc819825b21c693df5 (commit)
      from  0b9b6fcb36c8d69e4d8f900449ed29f19c5ca55d (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 f034f0e044b27e34b9e4e2fc819825b21c693df5
Author: Christopher Burger <burgerc at freeside.biz>
Date:   Wed Jan 23 11:18:19 2019 -0500

    RT# 79352 - fixed insert error where new contacts not tied to customer on insert.

diff --git a/FS/FS/contact.pm b/FS/FS/contact.pm
index 13f07a283..9775e7f6b 100644
--- a/FS/FS/contact.pm
+++ b/FS/FS/contact.pm
@@ -168,7 +168,6 @@ sub insert {
   my $existing_contact = '';
   my @contact_emails = ();
   my %contact_nums = ();
-  $contact_nums{$self->contactnum} = '1' if $self->contactnum;
 
   if ( $self->get('emailaddress') =~ /\S/ ) {
 
@@ -202,6 +201,8 @@ sub insert {
     return $error;
   }
 
+  $contact_nums{$self->contactnum} = '1' if $self->contactnum;
+
   my $cust_contact = '';
   # if $self->custnum was set, then the customer-specific properties
   # (custnum, classnum, invoice_dest, selfservice_access, comment) are in

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

Summary of changes:
 FS/FS/contact.pm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)




More information about the freeside-commits mailing list