Не отрабатывает проверка на незаполненность.
This commit is contained in:
parent
4d99a5bcad
commit
588f189f89
@ -22,8 +22,8 @@ function mail_send($to, $from_user, $from_email, $subject = '(No subject)', $mes
|
||||
|
||||
$login = filter_input(INPUT_POST, 'loginid', FILTER_SANITIZE_SPECIAL_CHARS);
|
||||
if ($login) {
|
||||
$recovery = db::c()->query('SELECT 1 FROM users_recovery WHERE login = "?s"', $login);
|
||||
if (!empty($recovery->getNumRows())) {
|
||||
$recovery = db::c()->query('SELECT 1 FROM users_recovery WHERE login = "?s"', $login)->getNumRows() ?? 0;
|
||||
if ($recovery) {
|
||||
$sql = db::c()->query('SELECT email FROM users WHERE login = "?s"', $login)->fetch_assoc();
|
||||
if ($sql) {
|
||||
$hash = bin2hex(random_bytes(8));
|
||||
|
Loading…
Reference in New Issue
Block a user