mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-11-07 17:36:07 +00:00
Fix issue #2094
This commit is contained in:
parent
75e7b0e37d
commit
003c4c3ab8
1 changed files with 10 additions and 1 deletions
|
|
@ -311,8 +311,17 @@ namespace MinecraftClient
|
||||||
// Try to refresh access token
|
// Try to refresh access token
|
||||||
if (!string.IsNullOrWhiteSpace(session.RefreshToken))
|
if (!string.IsNullOrWhiteSpace(session.RefreshToken))
|
||||||
{
|
{
|
||||||
result = ProtocolHandler.MicrosoftLoginRefresh(session.RefreshToken, out session);
|
try
|
||||||
|
{
|
||||||
|
result = ProtocolHandler.MicrosoftLoginRefresh(session.RefreshToken, out session);
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
ConsoleIO.WriteLine("Refresh access token fail: " + ex.Message);
|
||||||
|
result = ProtocolHandler.LoginResult.InvalidResponse;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (result != ProtocolHandler.LoginResult.Success
|
if (result != ProtocolHandler.LoginResult.Success
|
||||||
&& Settings.Password == ""
|
&& Settings.Password == ""
|
||||||
&& Settings.AccountType == ProtocolHandler.AccountType.Mojang)
|
&& Settings.AccountType == ProtocolHandler.AccountType.Mojang)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue