aboutsummaryrefslogtreecommitdiff
path: root/examples/http/http.tm
diff options
context:
space:
mode:
Diffstat (limited to 'examples/http/http.tm')
-rw-r--r--examples/http/http.tm4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/http/http.tm b/examples/http/http.tm
index 934c8690..f64a5048 100644
--- a/examples/http/http.tm
+++ b/examples/http/http.tm
@@ -64,7 +64,7 @@ func _send(method:_Method, url:Text, data:Text?, headers=[:Text] -> HTTPResponse
curl_easy_setopt(curl, CURLOPT_HTTPHEADER, chunk);
}
- code := 0[64]
+ code := Int64(0)
inline C {
CURLcode res = curl_easy_perform(curl);
if (res != CURLE_OK)
@@ -75,7 +75,7 @@ func _send(method:_Method, url:Text, data:Text?, headers=[:Text] -> HTTPResponse
curl_slist_free_all(chunk);
curl_easy_cleanup(curl);
}
- return HTTPResponse(code, "":join(chunks))
+ return HTTPResponse(Int(code), "":join(chunks))
func get(url:Text, headers=[:Text] -> HTTPResponse):
return _send(GET, url, !Text, headers)