Skip to content

Commit b4839e2

Browse files
committed
fix error message
1 parent 54aada1 commit b4839e2

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

cmd/src/main.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ package main
33
import (
44
"encoding/json"
55
"flag"
6-
"fmt"
76
"io"
87
"log"
98
"net"
@@ -284,7 +283,7 @@ func readConfig() (*config, error) {
284283
// no SRC_PROXY; check for the standard proxy env variables HTTP_PROXY, HTTPS_PROXY, and NO_PROXY
285284
if u, err := http.ProxyFromEnvironment(&http.Request{URL: cfg.endpointURL}); err != nil {
286285
// when there's an error, the value for the env variable is not a legit URL
287-
return nil, fmt.Errorf("Invalid HTTP_PROXY or HTTPS_PROXY value: %w", err)
286+
return nil, errors.Newf("invalid HTTP_PROXY or HTTPS_PROXY value: %w", err)
288287
} else {
289288
cfg.proxyURL = u
290289
}

0 commit comments

Comments
 (0)