docs(client): use Method::POST to match the example in https://hyper.rs/guides/client/advanced/ (#2479)

This commit is contained in:
Vagelis Prokopiou
2021-03-25 22:34:03 +02:00
committed by GitHub
parent 41f99578a5
commit 51ed71b0a6

View File

@@ -141,12 +141,12 @@ where
/// ``` /// ```
/// # #[cfg(feature = "runtime")] /// # #[cfg(feature = "runtime")]
/// # fn run () { /// # fn run () {
/// use hyper::{Body, Client, Request}; /// use hyper::{Body, Method, Client, Request};
/// ///
/// let client = Client::new(); /// let client = Client::new();
/// ///
/// let req = Request::builder() /// let req = Request::builder()
/// .method("POST") /// .method(Method::POST)
/// .uri("http://httpbin.org/post") /// .uri("http://httpbin.org/post")
/// .body(Body::from("Hallo!")) /// .body(Body::from("Hallo!"))
/// .expect("request builder"); /// .expect("request builder");