From b1a223fd6a814dae11fa4f4cc8a3b86555a5fa7d Mon Sep 17 00:00:00 2001 From: 3err0 Date: Wed, 27 May 2020 15:50:40 +0800 Subject: [PATCH] change send method command --- Miner | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/Miner b/Miner index 005d9d7..a3f9c40 100644 --- a/Miner +++ b/Miner @@ -24,12 +24,7 @@ def stats(ip): else: break - if command == "stats": - res = "STATS" - elif command == "devs": - res = "DEVS" - else: - res = "POOLS" + res = command.upper() result = json.loads(resp[:-1].replace('}{', '},{')) result = json.dumps(result[res]) @@ -40,4 +35,4 @@ def stats(ip): sock.shutdown(socket.SHUT_RDWR) sock.close() -stats(ip) +stats(ip) \ No newline at end of file