refactor(http): move h1 and h2 into http module

This commit is contained in:
Sean McArthur
2015-06-02 12:24:56 -07:00
parent 486a219bc8
commit 71ac65da5b
12 changed files with 351 additions and 350 deletions

View File

@@ -8,7 +8,7 @@ use std::io;
use hyper::Client;
use hyper::header::Connection;
use hyper::http2;
use hyper::http::h2;
fn main() {
env_logger::init().unwrap();
@@ -21,7 +21,7 @@ fn main() {
}
};
let mut client = Client::with_protocol(http2::new_protocol());
let mut client = Client::with_protocol(h2::new_protocol());
// `Connection: Close` is not a valid header for HTTP/2, but the client handles it gracefully.
let mut res = client.get(&*url)