If a player is not registered then we send a LOGIN plugin message on join (#2275)

* If a player is not registered then we send a LOGIN plugin message on join

* Make looking up a profile optionally quiet

This prevents an issue where a forcedLogin of a player that doesn't exist occurring when an unregistered player switches a server. The first login would tell AuthBungee that the player is logged in, and subsequent switches would have AuthBungee send a performLogin back that would then send an unregistered player error message to the player.

Co-authored-by: bundabrg <bundabrg@grieve.com.au>
Co-authored-by: Gabriele C <sgdc3.mail@gmail.com>
This commit is contained in:
bundabrg
2021-08-30 17:35:36 +08:00
committed by GitHub
parent 5426ada8f3
commit 80e37578b1
4 changed files with 49 additions and 5 deletions
@@ -152,7 +152,7 @@ public class BungeeReceiver implements PluginMessageListener, SettingsDependent
private void performLogin(final String name) {
Player player = bukkitService.getPlayerExact(name);
if (player != null && player.isOnline()) {
management.forceLogin(player);
management.forceLogin(player, true);
logger.info("The user " + player.getName() + " has been automatically logged in, "
+ "as requested via plugin messaging.");
} else {