mirror of
https://github.com/TuxCoding/FastLogin.git
synced 2026-05-05 12:14:34 +02:00
Fix NPE for skin apply in ProtocolLib mode (Related #182)
This commit is contained in:
+1
-1
@@ -69,7 +69,7 @@ public class ConnectListener implements Listener {
|
||||
session.setUuid(connection.getUniqueId());
|
||||
|
||||
PlayerProfile playerProfile = session.getProfile();
|
||||
playerProfile.setUUID(connection.getUniqueId());
|
||||
playerProfile.setUuid(connection.getUniqueId());
|
||||
|
||||
//bungeecord will do this automatically so override it on disabled option
|
||||
if (!plugin.getCore().getConfig().get("premiumUuid", true)) {
|
||||
|
||||
+1
-1
@@ -44,7 +44,7 @@ public class AsyncToggleMessage implements Runnable {
|
||||
}
|
||||
|
||||
playerProfile.setPremium(false);
|
||||
playerProfile.setUUID(null);
|
||||
playerProfile.setUuid(null);
|
||||
core.getStorage().save(playerProfile);
|
||||
sendMessage("remove-premium");
|
||||
}
|
||||
|
||||
@@ -11,7 +11,6 @@ import com.google.common.io.ByteStreams;
|
||||
import java.util.UUID;
|
||||
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.connection.PendingConnection;
|
||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||
import net.md_5.bungee.api.connection.Server;
|
||||
|
||||
@@ -22,15 +21,13 @@ public class ForceLoginTask
|
||||
|
||||
public ForceLoginTask(FastLoginCore<ProxiedPlayer, CommandSender, FastLoginBungee> core,
|
||||
ProxiedPlayer player, Server server) {
|
||||
super(core, player);
|
||||
super(core, player, core.getPlugin().getSession().get(player.getPendingConnection()));
|
||||
|
||||
this.server = server;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
PendingConnection pendingConnection = player.getPendingConnection();
|
||||
session = core.getPlugin().getSession().get(pendingConnection);
|
||||
if (session == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user