From aee76c58191efb792051b716d76b04d0d4d32e0f Mon Sep 17 00:00:00 2001 From: Brandon Date: Fri, 17 Mar 2023 22:17:22 +0100 Subject: [PATCH] net: update new_request (#17618) --- vlib/net/http/http.v | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vlib/net/http/http.v b/vlib/net/http/http.v index 090a406315..f12beda163 100644 --- a/vlib/net/http/http.v +++ b/vlib/net/http/http.v @@ -33,7 +33,7 @@ pub mut: // new_request creates a new Request given the request `method`, `url_`, and // `data`. -pub fn new_request(method Method, url_ string, data string) ?Request { +pub fn new_request(method Method, url_ string, data string) Request { url := if method == .get && !url_.contains('?') { url_ + '?' + data } else { url_ } // println('new req() method=$method url="$url" dta="$data"') return Request{