summaryrefslogtreecommitdiff
path: root/FS/FS/contact.pm
diff options
context:
space:
mode:
authorChristopher Burger <burgerc@freeside.biz>2019-01-23 11:18:19 -0500
committerChristopher Burger <burgerc@freeside.biz>2019-01-23 11:18:19 -0500
commitf034f0e044b27e34b9e4e2fc819825b21c693df5 (patch)
treef0c200af5fd968e1449bb1644a1518f1f785e796 /FS/FS/contact.pm
parent0b9b6fcb36c8d69e4d8f900449ed29f19c5ca55d (diff)
RT# 79352 - fixed insert error where new contacts not tied to customer on insert.
Diffstat (limited to 'FS/FS/contact.pm')
-rw-r--r--FS/FS/contact.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/FS/FS/contact.pm b/FS/FS/contact.pm
index 13f07a2..9775e7f 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