Mirror von
https://github.com/PaperMC/Velocity.git
synchronisiert 2024-11-17 05:20:14 +01:00
Add missing allowed check. Fixes #335
Dieser Commit ist enthalten in:
Ursprung
7ab56d0ca0
Commit
5a515f37a3
@ -219,9 +219,11 @@ public class ClientPlaySessionHandler implements MinecraftSessionHandler {
|
|||||||
PluginMessageEvent event = new PluginMessageEvent(player, serverConn, id,
|
PluginMessageEvent event = new PluginMessageEvent(player, serverConn, id,
|
||||||
ByteBufUtil.getBytes(packet.content()));
|
ByteBufUtil.getBytes(packet.content()));
|
||||||
server.getEventManager().fire(event).thenAcceptAsync(pme -> {
|
server.getEventManager().fire(event).thenAcceptAsync(pme -> {
|
||||||
PluginMessage message = new PluginMessage(packet.getChannel(),
|
if (pme.getResult().isAllowed()) {
|
||||||
Unpooled.wrappedBuffer(copy));
|
PluginMessage message = new PluginMessage(packet.getChannel(),
|
||||||
backendConn.write(message);
|
Unpooled.wrappedBuffer(copy));
|
||||||
|
backendConn.write(message);
|
||||||
|
}
|
||||||
}, backendConn.eventLoop());
|
}, backendConn.eventLoop());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren