aboutsummaryrefslogtreecommitdiff
path: root/app/class/controlleruser.php
diff options
context:
space:
mode:
Diffstat (limited to 'app/class/controlleruser.php')
-rw-r--r--app/class/controlleruser.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/class/controlleruser.php b/app/class/controlleruser.php
index 792877d..7863956 100644
--- a/app/class/controlleruser.php
+++ b/app/class/controlleruser.php
@@ -61,7 +61,7 @@ class Controlleruser extends Controller
$user->hydrate($_POST);
if(empty($user->id())) {
$this->routedirectget('user', ['error' => 'wrong_id']);
- } elseif (empty($user->password()) | $this->usermanager->passwordexist($user->password())) {
+ } elseif (!empty($_POST['password']) && (empty($user->password()) || $this->usermanager->passwordexist($user->password()))) {
$this->routedirectget('user', ['error' => 'change_password']);
} elseif (empty($user->level())) {
$this->routedirectget('user', ['error' => 'wrong_level']);