Skip to content

Commit

Permalink
gateway: fix clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
flomonster committed May 14, 2024
1 parent d49f3e8 commit f88f40d
Showing 1 changed file with 13 additions and 15 deletions.
28 changes: 13 additions & 15 deletions gateway/actix_auth/src/auth_middleware.rs
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
use std::{
future::{ready, Ready},
rc::Rc,
};
use actix_session::SessionExt;
use actix_web::dev::forward_ready;
use actix_web::dev::Service;
use actix_web::dev::ServiceRequest;
use actix_web::dev::ServiceResponse;
use actix_web::dev::Transform;
use actix_web::Error;
use actix_web::HttpMessage;
use std::future::ready;
use std::future::Ready;
use std::rc::Rc;

use actix_session::{Session, SessionExt};
use actix_web::{
dev::{forward_ready, Service, ServiceRequest, ServiceResponse, Transform},
Error, HttpMessage, HttpRequest,
};

use crate::{AuthContext, RequestAuth};

pub trait AuthGate: Clone {
fn filter(&self, req: &HttpRequest, session: Option<Session>) -> Option<actix_web::Error>;
}
use crate::AuthContext;
use crate::RequestAuth;

/// The MandatoryIdentityMiddleware does not directly process requests.
/// When actix starts, new_transform is called once per worker to create
Expand Down

0 comments on commit f88f40d

Please sign in to comment.