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:
@@ -15,6 +15,8 @@ import fr.xephi.authme.service.CommonService;
|
||||
import fr.xephi.authme.service.PluginHookService;
|
||||
import fr.xephi.authme.service.SessionService;
|
||||
import fr.xephi.authme.service.ValidationService;
|
||||
import fr.xephi.authme.service.bungeecord.BungeeSender;
|
||||
import fr.xephi.authme.service.bungeecord.MessageType;
|
||||
import fr.xephi.authme.settings.WelcomeMessageConfiguration;
|
||||
import fr.xephi.authme.settings.commandconfig.CommandManager;
|
||||
import fr.xephi.authme.settings.properties.HooksSettings;
|
||||
@@ -73,6 +75,9 @@ public class AsynchronousJoin implements AsynchronousProcess {
|
||||
@Inject
|
||||
private SessionService sessionService;
|
||||
|
||||
@Inject
|
||||
private BungeeSender bungeeSender;
|
||||
|
||||
@Inject
|
||||
private ProxySessionManager proxySessionManager;
|
||||
|
||||
@@ -148,6 +153,7 @@ public class AsynchronousJoin implements AsynchronousProcess {
|
||||
});
|
||||
|
||||
// Skip if registration is optional
|
||||
bungeeSender.sendAuthMeBungeecordMessage(MessageType.LOGIN, name);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user