diff options
author | boasting-squirrel <boasting.squirrel@gmail.com> | 2019-02-13 17:51:51 +0000 |
---|---|---|
committer | boasting-squirrel <boasting.squirrel@gmail.com> | 2019-02-13 17:51:51 +0000 |
commit | d410b27e85ffa653a64d10bcd6b43cc5f64fe5d9 (patch) | |
tree | 50bed1bf017347115b70db35c5034ae46695f182 /src/auth.rs | |
parent | Fixed Clippy warnings (diff) | |
download | miniserve-d410b27e85ffa653a64d10bcd6b43cc5f64fe5d9.tar.gz miniserve-d410b27e85ffa653a64d10bcd6b43cc5f64fe5d9.zip |
Removed config.rs and put back actix config in main.rs
Diffstat (limited to 'src/auth.rs')
-rw-r--r-- | src/auth.rs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/auth.rs b/src/auth.rs index 5d0bcaa..e39305c 100644 --- a/src/auth.rs +++ b/src/auth.rs @@ -2,8 +2,6 @@ use actix_web::http::header; use actix_web::middleware::{Middleware, Response}; use actix_web::{HttpRequest, HttpResponse, Result}; -use crate::config; - pub struct Auth; pub enum BasicAuthError { @@ -34,10 +32,10 @@ pub fn parse_basic_auth( }) } -impl Middleware<config::MiniserveConfig> for Auth { +impl Middleware<crate::MiniserveConfig> for Auth { fn response( &self, - req: &HttpRequest<config::MiniserveConfig>, + req: &HttpRequest<crate::MiniserveConfig>, resp: HttpResponse, ) -> Result<Response> { if let Some(ref required_auth) = req.state().auth { |