Commit 397ffcbf authored by Ben Boeckel's avatar Ben Boeckel
Browse files

cargo: update reqwest

parent 0b8fe8ff
......@@ -16,7 +16,7 @@ categories = ["web-programming", "api-bindings"]
hyper = { version = "~0.11", default-features = false }
itertools = "~0.7"
log = "~0.3"
reqwest = "~0.7"
reqwest = "~0.8"
serde_derive = "^1.0"
url = "^1.4"
......
......@@ -101,7 +101,7 @@ impl Gitlab {
.chain_err(|| ErrorKind::UrlParse)?;
let api = Gitlab {
client: Client::new()?,
client: Client::new(),
base_url: base_url,
token: token,
};
......@@ -533,7 +533,7 @@ impl Gitlab {
V: AsRef<str>,
{
let full_url = self.create_url_with_param(url, param)?;
let req = self.client.get(full_url)?;
let req = self.client.get(full_url);
self.send(req)
}
......@@ -543,8 +543,8 @@ impl Gitlab {
U: Serialize,
{
let full_url = self.create_url(url)?;
let mut req = self.client.post(full_url)?;
req.form(&param)?;
let mut req = self.client.post(full_url);
req.form(&param);
self.send(req)
}
......@@ -554,8 +554,8 @@ impl Gitlab {
U: Serialize,
{
let full_url = self.create_url(url)?;
let mut req = self.client.request(Method::Put, full_url)?;
req.form(&param)?;
let mut req = self.client.request(Method::Put, full_url);
req.form(&param);
self.send(req)
}
......@@ -588,7 +588,7 @@ impl Gitlab {
let mut page_url = full_url.clone();
page_url.query_pairs_mut()
.extend_pairs(&[("page", page_str), ("per_page", per_page_str)]);
let req = self.client.get(page_url)?;
let req = self.client.get(page_url);
let page: Vec<T> = self.send(req)?;
let page_len = page.len();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment