From 8971dbe3c3996f3216e728eb6cbafa734612747f Mon Sep 17 00:00:00 2001 From: Andrew Steinborn Date: Sat, 12 Oct 2024 18:21:01 -0400 Subject: [PATCH] Small cleanup --- .../com/velocitypowered/proxy/network/TransportType.java | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/proxy/src/main/java/com/velocitypowered/proxy/network/TransportType.java b/proxy/src/main/java/com/velocitypowered/proxy/network/TransportType.java index 3bece5e87..007326559 100644 --- a/proxy/src/main/java/com/velocitypowered/proxy/network/TransportType.java +++ b/proxy/src/main/java/com/velocitypowered/proxy/network/TransportType.java @@ -73,7 +73,6 @@ public enum TransportType { final ChannelFactory socketChannelFactory; final ChannelFactory datagramChannelFactory; final Supplier ioHandlerFactorySupplier; - volatile IoHandlerFactory ioHandlerFactory; TransportType(final String name, final ChannelFactory serverSocketChannelFactory, @@ -99,12 +98,8 @@ public enum TransportType { * @return the event loop group */ public EventLoopGroup createEventLoopGroup(final Type type) { - if (this.ioHandlerFactory == null) { - this.ioHandlerFactory = this.ioHandlerFactorySupplier.get(); - } - assert this.ioHandlerFactory != null; return new MultiThreadIoEventLoopGroup( - 0, createThreadFactory(this.name, type), this.ioHandlerFactory); + 0, createThreadFactory(this.name, type), this.ioHandlerFactorySupplier.get()); } private static ThreadFactory createThreadFactory(final String name, final Type type) {