Баги в регистрации.
This commit is contained in:
@@ -98,14 +98,13 @@ class UserRegister
|
||||
public static function new(string $login, string $password, string $email, $ref, $birthday, $sex): string
|
||||
{
|
||||
$password = password_hash($password, PASSWORD_DEFAULT);
|
||||
$ref = (int)$ref;
|
||||
$ip = UserIp::get();
|
||||
$sex = (int)$sex - 10; //Íà âõîäå 10\11, à ïåðåäàòü íàäî 0\1.
|
||||
Db::sql(
|
||||
'insert into users (users.real,login,host_reg,pass,ip,ipreg,room,timereg,mail,bithday,sex,fnq,molch2,level,hobby,clan_zv) values (1,?,?,?,?,?,9,unix_timestamp(),?,?,?,0,unix_timestamp() + 86400,8,\'\',0)',
|
||||
[
|
||||
$login,
|
||||
$ref,
|
||||
$ref ?? '',
|
||||
$password,
|
||||
$ip,
|
||||
$ip,
|
||||
|
||||
Reference in New Issue
Block a user