mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-11-15 03:31:15 +03:00
[FEATURE] email при регистрации
This commit is contained in:
parent
49e26d0d29
commit
d9c4cfdbc8
2 changed files with 3 additions and 0 deletions
|
@ -36,6 +36,7 @@ public class User {
|
|||
private byte[] password;
|
||||
private String accessToken;
|
||||
public String serverID;
|
||||
public String email;
|
||||
private String password_salt;
|
||||
public long permissions;
|
||||
//TODO: заменить EAGER на LASY и придумать способ сохранить сессию
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
public class RegisterResponse extends SimpleResponse {
|
||||
public String login;
|
||||
public String password;
|
||||
public String email;
|
||||
public byte[] verifyHash;
|
||||
@Override
|
||||
public void execute(ChannelHandlerContext ctx, Client client) throws Exception
|
||||
|
@ -32,6 +33,7 @@ public void execute(ChannelHandlerContext ctx, Client client) throws Exception
|
|||
}
|
||||
User user = new User();
|
||||
user.username = login;
|
||||
user.email = email;
|
||||
user.setPassword(password);
|
||||
user.uuid = UUID.randomUUID();
|
||||
server.config.dao.userService.saveUser(user);
|
||||
|
|
Loading…
Reference in a new issue