From: Ivan Kohler Date: Sat, 16 Dec 2017 00:43:48 +0000 (-0800) Subject: fix changing employee password, RT#78939 X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=commitdiff_plain;h=d6972edb74552fd097714121a8cc450b7d40bdbc fix changing employee password, RT#78939 --- diff --git a/FS/FS/Password_Mixin.pm b/FS/FS/Password_Mixin.pm index 122e3fd83..b29cf5713 100644 --- a/FS/FS/Password_Mixin.pm +++ b/FS/FS/Password_Mixin.pm @@ -82,7 +82,9 @@ sub is_password_allowed { return '' unless $self->get($self->primary_key); # for validating new passwords pre-insert #check against customer fields - my $cust_main = $self->cust_main; + my $cust_main = $self->table eq 'access_user' + ? $self->user_cust_main + : $self->cust_main; if ($cust_main) { my @words; # words from cust_main