diff options
author | ivan <ivan> | 2008-09-14 20:24:54 +0000 |
---|---|---|
committer | ivan <ivan> | 2008-09-14 20:24:54 +0000 |
commit | bd39d4e415d1ce8c9a8be76ffb05e9daed3e8b8d (patch) | |
tree | d741d4213fde53bbff6d4622659fdc388aebfdb8 | |
parent | 04cd55e337f3d9408e91ce371ef876e539ef2df5 (diff) |
silently strip out leading and trailing spaces from invoicing email addresses instead of throwing an error
-rw-r--r-- | FS/FS/cust_main_invoice.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/FS/FS/cust_main_invoice.pm b/FS/FS/cust_main_invoice.pm index 11d5a44b7..71148cab0 100644 --- a/FS/FS/cust_main_invoice.pm +++ b/FS/FS/cust_main_invoice.pm @@ -132,7 +132,7 @@ sub checkdest { } elsif ( $self->dest =~ /^(\d+)$/ ) { return "Unknown local account (specified by svcnum: ". $self->dest. ")" unless qsearchs( 'svc_acct', { 'svcnum' => $self->dest } ); - } elsif ( $self->dest =~ /^([\w\.\-\&\+]+)\@(([\w\.\-]+\.)+\w+)$/ ) { + } elsif ( $self->dest =~ /^\s*([\w\.\-\&\+]+)\@(([\w\.\-]+\.)+\w+)\s*$/ ) { my($user, $domain) = ($1, $2); $self->dest("$1\@$2"); } else { |