diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/dao/User.java b/LaunchServer/src/main/java/pro/gravit/launchserver/dao/User.java index 0573c2c3..c25d8c13 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/dao/User.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/dao/User.java @@ -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 и придумать способ сохранить сессию diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/RegisterResponse.java b/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/RegisterResponse.java index b5fae77e..97b89be9 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/RegisterResponse.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/RegisterResponse.java @@ -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);