From c9d03070a0f351275dee6506dd6687a162533b99 Mon Sep 17 00:00:00 2001 From: yuriy0803 <68668177+yuriy0803@users.noreply.github.com> Date: Tue, 23 Jul 2024 13:12:51 +0200 Subject: [PATCH] =?UTF-8?q?l=C3=B6schen?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- proxy/proto.go | 7 ------- proxy/stratum.go | 23 ----------------------- 2 files changed, 30 deletions(-) diff --git a/proxy/proto.go b/proxy/proto.go index e38187c..67659e3 100644 --- a/proxy/proto.go +++ b/proxy/proto.go @@ -44,10 +44,3 @@ type ErrorReply struct { Code int `json:"code"` Message string `json:"message"` } - -// Definiere den Typ JSONStratumResult -type JSONStratumResult struct { - Id interface{} `json:"id"` - Result interface{} `json:"result,omitempty"` - Error interface{} `json:"error,omitempty"` -} diff --git a/proxy/stratum.go b/proxy/stratum.go index 82c0ae2..6ea714a 100644 --- a/proxy/stratum.go +++ b/proxy/stratum.go @@ -156,29 +156,6 @@ func (cs *Session) handleTCPMessage(s *ProxyServer, req *StratumReq) error { cs.setStratumMode("EthProxy") log.Println("EthProxy login", cs.ip) return cs.sendTCPResult(req.Id, reply) - case "zilliqa switch": - // Setze den Stratum-Modus auf "Zilliqa" - cs.setStratumMode("Zilliqa") - - // Bestätige die Umschaltung an den Client - confirmationMessage := JSONStratumResult{ - Id: req.Id, - Result: "Stratum mode switched to Zilliqa. Currently no ZIL work available.", - } - err := cs.sendTCPResult(req.Id, confirmationMessage) - if err != nil { - return err - } - - // Senden einer Meldung an den Client, dass keine ZIL-Arbeit verfügbar ist - noZILWorkMessage := JSONStratumResult{ - Id: req.Id, - Result: "No ZIL work available at the moment.", - } - err = cs.sendTCPResult(req.Id, noZILWorkMessage) - if err != nil { - return err - } case "mining.subscribe": var params []string err := json.Unmarshal(req.Params, ¶ms)