diff options
author | vincent-peugnet <v.peugnet@free.fr> | 2020-04-09 20:19:37 +0200 |
---|---|---|
committer | vincent-peugnet <v.peugnet@free.fr> | 2020-04-09 20:19:37 +0200 |
commit | f29bb8688c02325196d7d5bd03fc528414f3055f (patch) | |
tree | 0043a0b21e69432010f2e907abf9034dee458076 /app/class/Controlleruser.php | |
parent | 0e66e1d890ca775b50b43990a4d92c035c1eb5b2 (diff) | |
download | wcms-f29bb8688c02325196d7d5bd03fc528414f3055f.tar.gz wcms-f29bb8688c02325196d7d5bd03fc528414f3055f.zip |
connect using user and password close #70
Diffstat (limited to 'app/class/Controlleruser.php')
-rw-r--r-- | app/class/Controlleruser.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/class/Controlleruser.php b/app/class/Controlleruser.php index 0ec8092..b148f5b 100644 --- a/app/class/Controlleruser.php +++ b/app/class/Controlleruser.php @@ -50,7 +50,7 @@ class Controlleruser extends Controller $user = new User($_POST); if(empty($user->id()) || $this->usermanager->get($user)) { $this->routedirectget('user', ['error' => 'wrong_id']); - } elseif(empty($user->password()) || $this->usermanager->passwordexist($user->password()) || !$user->validpassword()) { + } elseif(empty($user->password()) || !$user->validpassword()) { $this->routedirectget('user', ['error' => 'change_password']); } else { if($user->passwordhashed()) { @@ -102,7 +102,7 @@ class Controlleruser extends Controller $userupdate->hydrate($_POST); if(empty($userupdate->id())) { $this->routedirectget('user', ['error' => 'wrong_id']); - } elseif (!empty($_POST['password']) && (empty($userupdate->password()) || $this->usermanager->passwordexist($userupdate->password()) || !$userupdate->validpassword())) { + } elseif (!empty($_POST['password']) && (empty($userupdate->password()) || !$userupdate->validpassword())) { $this->routedirectget('user', ['error' => 'password_unvalid']); } elseif (empty($userupdate->level())) { $this->routedirectget('user', ['error' => 'wrong_level']); |