From b5aeac3ff21892b499ac0580e216e82e81d2006d Mon Sep 17 00:00:00 2001 From: Gravita Date: Fri, 15 Oct 2021 21:05:26 +0700 Subject: [PATCH] [FIX] Correct error in checkServer --- .../socket/response/auth/CheckServerResponse.java | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/CheckServerResponse.java b/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/CheckServerResponse.java index 82767345..9d41b9f0 100644 --- a/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/CheckServerResponse.java +++ b/LaunchServer/src/main/java/pro/gravit/launchserver/socket/response/auth/CheckServerResponse.java @@ -31,11 +31,13 @@ public void execute(ChannelHandlerContext ctx, Client pClient) { try { server.authHookManager.checkServerHook.hook(this, pClient); AuthManager.CheckServerReport report = server.authManager.checkServer(pClient, username, serverID); - if (report != null) { - result.playerProfile = report.playerProfile; - result.uuid = report.uuid; - logger.debug("checkServer: {} uuid: {} serverID: {}", result.playerProfile == null ? null : result.playerProfile.username, result.uuid, serverID); + if(report == null) { + sendError("User not verified"); + return; } + result.playerProfile = report.playerProfile; + result.uuid = report.uuid; + logger.debug("checkServer: {} uuid: {} serverID: {}", result.playerProfile == null ? null : result.playerProfile.username, result.uuid, serverID); } catch (AuthException | HookException e) { sendError(e.getMessage()); return;