1
0
mirror of https://github.com/GeyserMC/Geyser.git synced 2025-12-29 11:49:16 +00:00

Don't try to connect to the remote server with invalid credentials

Fixes #2458
This commit is contained in:
Camotoy
2021-08-12 14:35:26 -04:00
parent e20247b6d6
commit 919e84c23f

View File

@@ -590,9 +590,17 @@ public class GeyserSession implements CommandSender {
disconnect(LanguageUtils.getPlayerLocaleString("geyser.auth.login.invalid.kick", getClientData().getLanguageCode()));
} catch (RequestException ex) {
ex.printStackTrace();
disconnect(ex.getMessage());
}
return null;
}).whenComplete((aVoid, ex) -> connectDownstream());
}).whenComplete((aVoid, ex) -> {
if (this.closed) {
// Client disconnected during the authentication attempt
return;
}
connectDownstream();
});
}
/**