diff --git a/common/src/main/java/us/ajg0702/queue/common/QueueManagerImpl.java b/common/src/main/java/us/ajg0702/queue/common/QueueManagerImpl.java index f09e78e..f9a7c6a 100644 --- a/common/src/main/java/us/ajg0702/queue/common/QueueManagerImpl.java +++ b/common/src/main/java/us/ajg0702/queue/common/QueueManagerImpl.java @@ -433,6 +433,7 @@ public class QueueManagerImpl implements QueueManager { for (QueuePlayer queuePlayer : s.getQueue()) { AdaptedPlayer player = queuePlayer.getPlayer(); if (player == null || !player.isConnected()) continue; + if(player.getServerName() == null) continue; main.getPlatformMethods().sendPluginMessage(player, "inqueueevent", "true"); } } diff --git a/platforms/velocity/src/main/java/us/ajg0702/queue/platforms/velocity/players/VelocityPlayer.java b/platforms/velocity/src/main/java/us/ajg0702/queue/platforms/velocity/players/VelocityPlayer.java index cd1c478..206e05e 100644 --- a/platforms/velocity/src/main/java/us/ajg0702/queue/platforms/velocity/players/VelocityPlayer.java +++ b/platforms/velocity/src/main/java/us/ajg0702/queue/platforms/velocity/players/VelocityPlayer.java @@ -106,7 +106,7 @@ public class VelocityPlayer implements AdaptedPlayer, Audience { @Override public String getServerName() { Optional serverConnection = handle.getCurrentServer(); - if(!serverConnection.isPresent()) return "none"; + if(!serverConnection.isPresent()) return null; ServerConnection connection = serverConnection.get(); return connection.getServerInfo().getName(); }