Set default http request method
This commit is contained in:
1 parent
e941bc2439
commit
3c43934081
1 file changed
+1
-3
@@ -61,6 +61,7 @@ namespace HttpClient
|
||||
function new()
|
||||
m._timeoutSeconds = 30
|
||||
m._tryCount = 1
|
||||
m._method = "GET"
|
||||
end function
|
||||
|
||||
function Method(method as string) as HttpRequest
|
||||
@@ -249,9 +250,6 @@ namespace HttpClient
|
||||
else if m._method = "HEAD"
|
||||
m._sent = m.urlTransfer.AsyncHead()
|
||||
else
|
||||
if StringUtils.IsNullOrEmpty(m._method)
|
||||
throw "Http request method not set"
|
||||
end if
|
||||
m.urlTransfer.SetRequest(m._method)
|
||||
body = m._body
|
||||
if body = invalid
|
||||
|
||||
Reference in new issue
Block a user