From f211787b8485a1fa466608b048ae31a8f878105c Mon Sep 17 00:00:00 2001 From: malong Date: Thu, 14 Jun 2018 12:07:04 +0800 Subject: [PATCH] fixed close --- request.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/request.go b/request.go index 43246f2..5e96ee5 100644 --- a/request.go +++ b/request.go @@ -146,6 +146,9 @@ func buildHTTPRequest(method string, url string, a *Args) (req *http.Request, er if a.BasicAuth.Username != "" { req.SetBasicAuth(a.BasicAuth.Username, a.BasicAuth.Password) } + if a.Close == true { + req.Close = true + } return }