1
0
Fork 0
mirror of https://github.com/diamondburned/arikawa.git synced 2024-11-01 04:24:19 +00:00

utils: dont set http.Client timeout to a default value

This commit is contained in:
Benbebop 2024-09-15 22:33:00 -06:00 committed by Diamond
parent 67f94a835a
commit 6f5a53063f

View file

@ -5,7 +5,6 @@ import (
"io"
"net/http"
"net/url"
"time"
)
// DefaultClient implements Client and wraps around the stdlib Client.
@ -19,12 +18,9 @@ func WrapClient(client http.Client) Client {
return DefaultClient(client)
}
// NewClient creates a new client around the standard library's http.Client. The
// client will have a timeout of 10 seconds.
// NewClient creates a new client around the standard library's http.Client.
func NewClient() Client {
return WrapClient(http.Client{
Timeout: 10 * time.Second,
})
return WrapClient(http.Client{})
}
func (d DefaultClient) NewRequest(ctx context.Context, method, url string) (Request, error) {