We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 625c565 commit 594ba1dCopy full SHA for 594ba1d
net/http/tinygo.go
@@ -20,6 +20,11 @@ func SetBuf(b []byte) {
20
}
21
22
func (c *Client) Do(req *Request) (*Response, error) {
23
+ if c.Jar != nil {
24
+ for _, cookie := range c.Jar.Cookies(req.URL) {
25
+ req.AddCookie(cookie)
26
+ }
27
28
switch req.URL.Scheme {
29
case "http":
30
return c.doHTTP(req)
@@ -31,12 +36,6 @@ func (c *Client) Do(req *Request) (*Response, error) {
31
36
32
37
33
38
func (c *Client) doHTTP(req *Request) (*Response, error) {
34
- if c.Jar != nil {
35
- for _, cookie := range c.Jar.Cookies(req.URL) {
- req.AddCookie(cookie)
- }
39
-
40
// make TCP connection
41
ip := net.ParseIP(req.URL.Hostname())
42
port := 80
0 commit comments