Преглед на файлове

refactor: use httputil.NewClientWithDriver func

ayn2op преди 7 месеца
родител
ревизия
93f6873ffc
променени са 1 файла, в които са добавени 1 реда и са изтрити 2 реда
  1. 1 2
      internal/http/client.go

+ 1 - 2
internal/http/client.go

@@ -9,9 +9,8 @@ import (
 )
 
 func NewClient(token string) *api.Client {
-	httpClient := httputil.NewClient()
 	stdClient := http.DefaultClient
 	stdClient.Transport = NewTransport()
-	httpClient.Client = httpdriver.WrapClient(*stdClient)
+	httpClient := httputil.NewClientWithDriver(httpdriver.WrapClient(*stdClient))
 	return api.NewCustomClient(token, httpClient)
 }