Meremoved unused variable

This commit is contained in:
Alfred Kamanda 2024-11-07 23:57:12 +03:00
parent 4b3273c44e
commit 60970e235d
Signed by: Alfred-mk
GPG Key ID: 7EA3D01708908703

View File

@ -216,17 +216,17 @@ func doRequest(ctx context.Context, req *http.Request, rcpt any) (*api.OKRespons
func doCustodialRequest(ctx context.Context, req *http.Request, rcpt any) (*api.OKResponse, error) { func doCustodialRequest(ctx context.Context, req *http.Request, rcpt any) (*api.OKResponse, error) {
req.Header.Set("X-GE-KEY", config.CustodialAPIKey) req.Header.Set("X-GE-KEY", config.CustodialAPIKey)
logRequestDetails(req, config.CustodialAPIKey) logRequestDetails(req)
return doRequest(ctx, req, rcpt) return doRequest(ctx, req, rcpt)
} }
func doDataRequest(ctx context.Context, req *http.Request, rcpt any) (*api.OKResponse, error) { func doDataRequest(ctx context.Context, req *http.Request, rcpt any) (*api.OKResponse, error) {
req.Header.Set("X-GE-KEY", config.DataAPIKey) req.Header.Set("X-GE-KEY", config.DataAPIKey)
logRequestDetails(req, config.CustodialAPIKey) logRequestDetails(req)
return doRequest(ctx, req, rcpt) return doRequest(ctx, req, rcpt)
} }
func logRequestDetails(req *http.Request, apiKey string) { func logRequestDetails(req *http.Request) {
var bodyBytes []byte var bodyBytes []byte
contentType := req.Header.Get("Content-Type") contentType := req.Header.Get("Content-Type")
if req.Body != nil { if req.Body != nil {