mirror of
https://github.com/fluxcd/flagger.git
synced 2026-04-15 06:57:34 +00:00
don't override DefaultClient
bug introduced by https://github.com/fluxcd/flagger/pull/872 Signed-off-by: Léopold Jacquot <leopold.jacquot@infomaniak.com>
This commit is contained in:
@@ -61,10 +61,7 @@ func callWebhook(webhook string, payload interface{}, timeout string) error {
|
||||
ctx, cancel := context.WithTimeout(req.Context(), t)
|
||||
defer cancel()
|
||||
|
||||
httpClient := http.DefaultClient
|
||||
httpClient.Transport = http.DefaultTransport
|
||||
|
||||
r, err := httpClient.Do(req.WithContext(ctx))
|
||||
r, err := http.DefaultClient.Do(req.WithContext(ctx))
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -30,7 +30,7 @@ import (
|
||||
)
|
||||
|
||||
func postMessage(address string, proxy string, payload interface{}) error {
|
||||
httpClient := http.DefaultClient
|
||||
var httpClient = &http.Client{}
|
||||
|
||||
if proxy != "" {
|
||||
proxyURL, err := url.Parse(proxy)
|
||||
|
||||
Reference in New Issue
Block a user