mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-09 04:39:24 +00:00
hyper-rustls 0.26 (#519)
* hyper-rustls 0.25 This isn't worth it until our dependencies update to rustls 0.22 as well. * hyper-rustls 0.26 and hyper 1.0
This commit is contained in:
@@ -1,12 +1,13 @@
|
||||
use hyper::body::Body;
|
||||
use hyper::body::Bytes;
|
||||
#[cfg(feature = "basic-auth")]
|
||||
use hyper::header::HeaderValue;
|
||||
pub use http_body_util::Full;
|
||||
|
||||
#[cfg(feature = "basic-auth")]
|
||||
use crate::Error;
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct Request(pub(crate) hyper::Request<Body>);
|
||||
pub struct Request(pub(crate) hyper::Request<Full<Bytes>>);
|
||||
impl Request {
|
||||
#[cfg(feature = "basic-auth")]
|
||||
fn username_password_from_uri(&self) -> Result<(String, String), Error> {
|
||||
@@ -59,8 +60,8 @@ impl Request {
|
||||
let _ = self.basic_auth_from_uri();
|
||||
}
|
||||
}
|
||||
impl From<hyper::Request<Body>> for Request {
|
||||
fn from(request: hyper::Request<Body>) -> Request {
|
||||
impl From<hyper::Request<Full<Bytes>>> for Request {
|
||||
fn from(request: hyper::Request<Full<Bytes>>) -> Request {
|
||||
Request(request)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user