forked from TuxCoding/FastLogin
Fix creating logging session in ProtocolSupport environments
Fixes #251
This commit is contained in:
@ -40,6 +40,11 @@ public class BukkitLoginSession extends LoginSession {
|
|||||||
this(username, "", EMPTY_ARRAY, false, profile);
|
this(username, "", EMPTY_ARRAY, false, profile);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//ProtocolSupport
|
||||||
|
public BukkitLoginSession(String username, boolean registered, StoredProfile profile) {
|
||||||
|
this(username, "", EMPTY_ARRAY, registered, profile);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets the verify token the server sent to the client.
|
* Gets the verify token the server sent to the client.
|
||||||
*
|
*
|
||||||
|
@ -73,8 +73,7 @@ public class ProtocolSupportListener extends JoinManagement<Player, CommandSende
|
|||||||
String ip = source.getAddress().getAddress().getHostAddress();
|
String ip = source.getAddress().getAddress().getHostAddress();
|
||||||
plugin.getCore().getPendingLogin().put(ip + username, new Object());
|
plugin.getCore().getPendingLogin().put(ip + username, new Object());
|
||||||
|
|
||||||
BukkitLoginSession playerSession = new BukkitLoginSession(username, null, null
|
BukkitLoginSession playerSession = new BukkitLoginSession(username, registered, profile);
|
||||||
, registered, profile);
|
|
||||||
plugin.getLoginSessions().put(source.getAddress().toString(), playerSession);
|
plugin.getLoginSessions().put(source.getAddress().toString(), playerSession);
|
||||||
if (plugin.getConfig().getBoolean("premiumUuid")) {
|
if (plugin.getConfig().getBoolean("premiumUuid")) {
|
||||||
source.getLoginStartEvent().setOnlineMode(true);
|
source.getLoginStartEvent().setOnlineMode(true);
|
||||||
|
Reference in New Issue
Block a user