mirror of
https://github.com/PaperMC/Velocity.git
synced 2025-03-01 15:55:45 +08:00
Fix sendPluginMessage (#926)
This commit is contained in:
parent
d9ee34feac
commit
8a048f0505
@ -155,9 +155,10 @@ public class VelocityRegisteredServer implements RegisteredServer, ForwardingAud
|
||||
*/
|
||||
public boolean sendPluginMessage(ChannelIdentifier identifier, ByteBuf data) {
|
||||
for (ConnectedPlayer player : players.values()) {
|
||||
VelocityServerConnection connection = player.getConnectedServer();
|
||||
if (connection != null && connection.getServer() == this) {
|
||||
return connection.sendPluginMessage(identifier, data);
|
||||
VelocityServerConnection serverConnection = player.getConnectedServer();
|
||||
if (serverConnection != null && serverConnection.getConnection() != null
|
||||
&& serverConnection.getServer() == this) {
|
||||
return serverConnection.sendPluginMessage(identifier, data);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user