diff --git a/protocol/crypto/crypto.go b/internal/crypto/crypto.go similarity index 98% rename from protocol/crypto/crypto.go rename to internal/crypto/crypto.go index 34e65bea..7de14c09 100644 --- a/protocol/crypto/crypto.go +++ b/internal/crypto/crypto.go @@ -96,7 +96,7 @@ func (e *EncryptECDH) FetchPubKey(uin int64) { if err != nil { return } - defer resp.Body.Close() + defer func() { _ = resp.Body.Close() }() pubKey := pubKeyResp{} err = json.NewDecoder(resp.Body).Decode(&pubKey) if err != nil {