From ea4c24c76e3ef95f73aace155f3c49e5e798b607 Mon Sep 17 00:00:00 2001 From: Jose Quintana Date: Sat, 12 Nov 2022 23:04:38 +0100 Subject: [PATCH] style: reorder imports on tls module --- src/tls.rs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/tls.rs b/src/tls.rs index 3701411..96cea6b 100644 --- a/src/tls.rs +++ b/src/tls.rs @@ -1,6 +1,9 @@ // Handles requests over TLS // -> Most of the file is borrowed from https://github.com/seanmonstar/warp/blob/master/src/tls.rs +use futures_util::ready; +use hyper::server::accept::Accept; +use hyper::server::conn::{AddrIncoming, AddrStream}; use std::fs::File; use std::future::Future; use std::io::{self, BufReader, Cursor, Read}; @@ -10,17 +13,13 @@ use std::pin::Pin; use std::sync::Arc; use std::task::{Context, Poll}; use tokio::io::{AsyncRead, AsyncWrite, ReadBuf}; - -use futures_util::ready; -use hyper::server::accept::Accept; -use hyper::server::conn::{AddrIncoming, AddrStream}; - -use crate::transport::Transport; use tokio_rustls::rustls::{ server::{AllowAnyAnonymousOrAuthenticatedClient, AllowAnyAuthenticatedClient, NoClientAuth}, Certificate, Error as TlsError, PrivateKey, RootCertStore, ServerConfig, }; +use crate::transport::Transport; + /// Represents errors that can occur building the TlsConfig #[derive(Debug)] pub enum TlsConfigError { -- libgit2 1.7.2