mirror of
https://github.com/tinygo-org/drivers.git
synced 2026-08-04 06:57:48 +00:00
Add support for req.URL.RawQuery
This commit is contained in:
@@ -56,6 +56,9 @@ func (c *Client) doHTTP(req *Request) (*Response, error) {
|
||||
if p == "" {
|
||||
p = "/"
|
||||
}
|
||||
if req.URL.RawQuery != "" {
|
||||
p += "?" + req.URL.RawQuery
|
||||
}
|
||||
fmt.Fprintln(conn, req.Method+" "+p+" HTTP/1.1")
|
||||
fmt.Fprintln(conn, "Host:", req.URL.Host)
|
||||
|
||||
@@ -114,6 +117,9 @@ func (c *Client) doHTTPS(req *Request) (*Response, error) {
|
||||
if p == "" {
|
||||
p = "/"
|
||||
}
|
||||
if req.URL.RawQuery != "" {
|
||||
p += "?" + req.URL.RawQuery
|
||||
}
|
||||
fmt.Fprintln(conn, req.Method+" "+p+" HTTP/1.1")
|
||||
fmt.Fprintln(conn, "Host:", req.URL.Host)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user