diff --git a/MultiAdmin/ServerIO/ServerSocket.cs b/MultiAdmin/ServerIO/ServerSocket.cs index 0f74822..19c028f 100644 --- a/MultiAdmin/ServerIO/ServerSocket.cs +++ b/MultiAdmin/ServerIO/ServerSocket.cs @@ -23,21 +23,9 @@ public class ServerSocket : IDisposable public event EventHandler OnReceiveMessage; - public int Port - { - get - { - return ((IPEndPoint)listener.LocalEndpoint).Port; - } - } + public int Port => ((IPEndPoint)listener.LocalEndpoint).Port; - public bool Connected - { - get - { - return client?.Connected ?? false; - } - } + public bool Connected => client?.Connected ?? false; // Port 0 automatically assigns a port public ServerSocket(int port = 0)