mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
CHORE: Fix golint and staticcheck errors/warnings (#2717)
This commit is contained in:
@@ -4,7 +4,7 @@ import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"io/ioutil"
|
||||
"io"
|
||||
"log"
|
||||
"net/http"
|
||||
"path"
|
||||
@@ -69,7 +69,7 @@ func dnssdkDo(ctx context.Context, c *dnssdk.Client, apiKey string, method, uri
|
||||
defer func() { _ = resp.Body.Close() }()
|
||||
|
||||
if resp.StatusCode >= http.StatusMultipleChoices {
|
||||
all, _ := ioutil.ReadAll(resp.Body)
|
||||
all, _ := io.ReadAll(resp.Body)
|
||||
e := dnssdk.APIError{
|
||||
StatusCode: resp.StatusCode,
|
||||
}
|
||||
|
Reference in New Issue
Block a user