From 4a95db64d0f21cee375e39acb824b1500f2447f7 Mon Sep 17 00:00:00 2001 From: swee Date: Sat, 25 Jan 2025 20:36:41 -0800 Subject: [PATCH] Update server.py --- server.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server.py b/server.py index a49b09b..6403db2 100644 --- a/server.py +++ b/server.py @@ -289,7 +289,8 @@ def session(connection, client, ip, isssl=False): elif command == "PING": try: e = text.split(" ")[1] - connection.sendall(bytes(f":{server} PONG {server} :{e}\r\n","UTF-8")) + e = f":{e}" if e[0] != ":" else e + connection.sendall(bytes(f":{server} PONG {server} {e}\r\n","UTF-8")) except: connection.sendall(bytes(f":{server} PONG {server}\r\n","UTF-8")) elif command == "MOTD":