mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-26 02:47:44 +01:00
Ignore empty messages (not just null) for join and quit
This commit is contained in:
parent
aa90f2ff9c
commit
91b673e375
@ -648,7 +648,7 @@ public class NetServerHandler extends NetHandler implements ICommandListener {
|
||||
a.info(this.player.name + " lost connection: " + s);
|
||||
// CraftBukkit start - we need to handle custom quit messages
|
||||
String quitMessage = this.minecraftServer.serverConfigurationManager.disconnect(this.player);
|
||||
if (quitMessage != null) {
|
||||
if ((quitMessage != null) && (quitMessage.length() > 0)) {
|
||||
this.minecraftServer.serverConfigurationManager.sendAll(new Packet3Chat(quitMessage));
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
@ -130,7 +130,7 @@ public class ServerConfigurationManager {
|
||||
|
||||
String joinMessage = playerJoinEvent.getJoinMessage();
|
||||
|
||||
if (joinMessage != null) {
|
||||
if ((joinMessage != null) && (joinMessage.length() > 0)) {
|
||||
this.server.serverConfigurationManager.sendAll(new Packet3Chat(joinMessage));
|
||||
}
|
||||
// CraftBukkit end
|
||||
|
Loading…
Reference in New Issue
Block a user