Throw exception when ServerConnectEvent is handled badly
This commit is contained in:
parent
8574688be7
commit
4d004d5fed
@ -252,6 +252,11 @@ public final class UserConnection implements ProxiedPlayer
|
|||||||
{
|
{
|
||||||
callback.done( false, null );
|
callback.done( false, null );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ( getServer() == null && !ch.isClosing() )
|
||||||
|
{
|
||||||
|
throw new IllegalStateException("Cancelled ServerConnectEvent with no server or disconnect.");
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user