Commit ae77a4bb authored by wang's avatar wang

cronet

parent ba3c128e
......@@ -63,7 +63,7 @@ func (c *Client) Start() error {
}
if strings.ToUpper(c.Item.Method) == "GET" {
req, err = http.NewRequest(http.MethodGet, c.Item.Url, nil)
} else if strings.ToUpper(c.Item.Method) == "GET" {
} else if strings.ToUpper(c.Item.Method) == http.MethodOptions {
req, err = http.NewRequest(http.MethodOptions, c.Item.Url, nil)
} else {
req, err = http.NewRequest(http.MethodPost, c.Item.Url, strings.NewReader(c.Item.Data))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment