net.http: default explicitly to Method.get for http.Request and http.FetchConfig too

This commit is contained in:
Delyan Angelov 2023-09-06 12:03:19 +03:00
parent 330dda59c8
commit c7ebc477b0
No known key found for this signature in database
GPG Key ID: 66886C0F12D595ED
2 changed files with 2 additions and 2 deletions

View File

@ -15,7 +15,7 @@ const (
pub struct FetchConfig { pub struct FetchConfig {
pub mut: pub mut:
url string url string
method Method method Method = .get
header Header header Header
data string data string
params map[string]string params map[string]string

View File

@ -21,7 +21,7 @@ pub type RequestFinishFn = fn (request &Request, final_size u64) !
pub struct Request { pub struct Request {
pub mut: pub mut:
version Version = .v1_1 version Version = .v1_1
method Method method Method = .get
header Header header Header
host string host string
cookies map[string]string cookies map[string]string