mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-11-15 11:39:11 +03:00
[FIX] Обращение к AuthHandler'у
This commit is contained in:
parent
eca8cc2cbc
commit
e7fd749c2f
1 changed files with 12 additions and 6 deletions
|
@ -98,14 +98,20 @@ public void execute(ChannelHandlerContext ctx, Client clientData) throws Excepti
|
||||||
}
|
}
|
||||||
result.session = clientData.session;
|
result.session = clientData.session;
|
||||||
}
|
}
|
||||||
UUID uuid = pair.handler.auth(aresult);
|
UUID uuid;
|
||||||
result.playerProfile = ProfileByUUIDResponse.getProfile(uuid, aresult.username, client, clientData.auth.textureProvider);
|
if (authType == ConnectTypes.CLIENT && server.config.protectHandler.allowGetAccessToken(context)) {
|
||||||
if (authType == ConnectTypes.API || !server.config.protectHandler.allowGetAccessToken(context)) {
|
uuid = pair.handler.auth(aresult);
|
||||||
result.accessToken = null;
|
if (LogHelper.isDebugEnabled()) {
|
||||||
}
|
|
||||||
else if (LogHelper.isDebugEnabled()) {
|
|
||||||
LogHelper.debug("Auth: %s accessToken %s uuid: %s", login, result.accessToken, uuid.toString());
|
LogHelper.debug("Auth: %s accessToken %s uuid: %s", login, result.accessToken, uuid.toString());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
uuid = pair.handler.usernameToUUID(aresult.username);
|
||||||
|
result.accessToken = null;
|
||||||
|
}
|
||||||
|
result.playerProfile = ProfileByUUIDResponse.getProfile(uuid, aresult.username, client, clientData.auth.textureProvider);
|
||||||
|
|
||||||
clientData.type = authType;
|
clientData.type = authType;
|
||||||
sendResult(result);
|
sendResult(result);
|
||||||
} catch (AuthException | HookException e) {
|
} catch (AuthException | HookException e) {
|
||||||
|
|
Loading…
Reference in a new issue