From bb4945b51338de72d0a94ecb628bc3756e03870a Mon Sep 17 00:00:00 2001 From: Andrew Steinborn Date: Sat, 24 Nov 2018 20:12:29 -0500 Subject: [PATCH] Fix awkward disconnection issues. --- .../proxy/connection/backend/BackendPlaySessionHandler.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/BackendPlaySessionHandler.java b/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/BackendPlaySessionHandler.java index 3be1bfeba..04f03f764 100644 --- a/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/BackendPlaySessionHandler.java +++ b/proxy/src/main/java/com/velocitypowered/proxy/connection/backend/BackendPlaySessionHandler.java @@ -160,8 +160,7 @@ public class BackendPlaySessionHandler implements MinecraftSessionHandler { public void disconnected() { serverConn.getServer().removePlayer(serverConn.getPlayer()); if (!serverConn.isGracefulDisconnect()) { - serverConn.getPlayer().handleConnectionException(serverConn.getServer(), Disconnect.create( - ConnectionMessages.UNEXPECTED_DISCONNECT)); + serverConn.getPlayer().disconnect(ConnectionMessages.UNEXPECTED_DISCONNECT); } }