From fa44f021d2ad669552dd165220254efbfc9914ea Mon Sep 17 00:00:00 2001 From: RaphiMC <50594595+RaphiMC@users.noreply.github.com> Date: Tue, 29 Oct 2024 17:12:10 +0100 Subject: [PATCH] Removed unused code --- .../raphimc/viaproxy/proxy/util/ExceptionUtil.java | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/src/main/java/net/raphimc/viaproxy/proxy/util/ExceptionUtil.java b/src/main/java/net/raphimc/viaproxy/proxy/util/ExceptionUtil.java index f2831b3..65476eb 100644 --- a/src/main/java/net/raphimc/viaproxy/proxy/util/ExceptionUtil.java +++ b/src/main/java/net/raphimc/viaproxy/proxy/util/ExceptionUtil.java @@ -17,7 +17,6 @@ */ package net.raphimc.viaproxy.proxy.util; -import com.viaversion.viaversion.exception.InformativeException; import io.netty.channel.ChannelHandlerContext; import io.netty.handler.codec.DecoderException; import io.netty.handler.codec.EncoderException; @@ -25,22 +24,10 @@ import net.raphimc.viaproxy.ViaProxy; import net.raphimc.viaproxy.proxy.session.ProxyConnection; import net.raphimc.viaproxy.util.logging.Logger; -import java.lang.reflect.Field; import java.nio.channels.ClosedChannelException; public class ExceptionUtil { - private static Field infoField; - - static { - try { - infoField = InformativeException.class.getDeclaredField("info"); - infoField.setAccessible(true); - } catch (Throwable e) { - e.printStackTrace(); - } - } - public static void handleNettyException(ChannelHandlerContext ctx, Throwable cause, ProxyConnection proxyConnection, boolean client2Proxy) { if (!ctx.channel().isOpen()) return; if (cause instanceof ClosedChannelException) return;