Skip to content

Commit ef57326

Browse files
committed
Move password check before verification check
1 parent 8549432 commit ef57326

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/controllers/User/Login.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,10 @@ protected function tryLogin(Router &$router, UserLoginModel &$model) {
7878
$model->error = "USER_NOT_FOUND";
7979
} else if ($user->isDisabled()) {
8080
$model->error = "USER_DISABLED";
81-
} else if (!$user->isVerified()) {
82-
$model->error = "USER_NOT_VERIFIED";
8381
} else if (!$user->checkPassword($password)) {
8482
$model->error = "PASSWORD_INCORRECT";
83+
} else if (!$user->isVerified()) {
84+
$model->error = "USER_NOT_VERIFIED";
8585
}
8686

8787
if ($model->error) return;

0 commit comments

Comments
 (0)