Skip to content

Commit

Permalink
fix(extensions/packet): actually cancel packets cancelled by ViaVersion
Browse files Browse the repository at this point in the history
  • Loading branch information
Misat11 committed Dec 29, 2024
1 parent bc3d5f3 commit 792d008
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,12 @@ protected void sendRawPacket(Player player, ByteBuf buffer) {
if (conn != null) {
try {
conn.transformClientbound(buffer, CancelEncoderException::generate);
} catch (Throwable ignored) {
// no u Via
} catch (Throwable ex) {
// Cancelled by Via
if (!(ex instanceof CancelEncoderException)) {
ex.printStackTrace();
}
return;
}
}

Expand Down

0 comments on commit 792d008

Please sign in to comment.