diff options
| author | Christopher Burger <burgerc@freeside.biz> | 2019-05-07 12:02:22 -0400 |
|---|---|---|
| committer | Christopher Burger <burgerc@freeside.biz> | 2019-05-07 15:31:37 -0400 |
| commit | 41baff41be27f0df19234232a0bffea69c323009 (patch) | |
| tree | fcccd08ad10ce36b38b5ad90ea922774fd546a96 | |
| parent | 4f53fbbb88637f3c7d44db2e16933d1754323b78 (diff) | |
RT# 82132 - updated password reset by mail to use username-uppercase config
Conflicts:
FS/FS/ClientAPI/MyAccount.pm
| -rw-r--r-- | FS/FS/ClientAPI/MyAccount.pm | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/FS/FS/ClientAPI/MyAccount.pm b/FS/FS/ClientAPI/MyAccount.pm index dae2e1929..470d12b11 100644 --- a/FS/FS/ClientAPI/MyAccount.pm +++ b/FS/FS/ClientAPI/MyAccount.pm @@ -3130,7 +3130,11 @@ sub reset_passwd { my $cust_main = ''; if ( $p->{'email'} ) { #new-style, changes contact and svc_acct - $contact = FS::contact->by_selfservice_email($p->{'email'}); + $contact = FS::contact->by_selfservice_email($p->{'email'}, 'case_insensitive'); + + if ($conf->exists('username-uppercase') || $conf->exists('username-uppercase', $contact->cust_main->agentnum)) { + $contact = FS::contact->by_selfservice_email_custnum($p->{email}, $contact->custnum); + } $cust_main = $contact->cust_main if $contact; |
