cargo clippy
This commit is contained in:
parent
5633aae029
commit
88e34902c0
@ -36,7 +36,7 @@ impl Session {
|
|||||||
#[rtype(result = "()")]
|
#[rtype(result = "()")]
|
||||||
pub struct PushNewSession(pub Session);
|
pub struct PushNewSession(pub Session);
|
||||||
|
|
||||||
|
#[derive(Default)]
|
||||||
pub struct OpenIDSessionsActor {
|
pub struct OpenIDSessionsActor {
|
||||||
session: Vec<Session>,
|
session: Vec<Session>,
|
||||||
}
|
}
|
||||||
@ -47,12 +47,6 @@ impl OpenIDSessionsActor {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl Default for OpenIDSessionsActor {
|
|
||||||
fn default() -> Self {
|
|
||||||
Self { session: vec![] }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
impl Actor for OpenIDSessionsActor {
|
impl Actor for OpenIDSessionsActor {
|
||||||
type Context = Context<Self>;
|
type Context = Context<Self>;
|
||||||
|
|
||||||
|
@ -87,8 +87,7 @@ pub async fn authorize(user: CurrentUser, query: web::Query<AuthorizeQuery>,
|
|||||||
}.render().unwrap());
|
}.render().unwrap());
|
||||||
}
|
}
|
||||||
|
|
||||||
let scopes = query.scope.split(' ').collect::<Vec<_>>();
|
if !query.scope.split(' ').any(|x| x == "openid") {
|
||||||
if !scopes.contains(&"openid") {
|
|
||||||
return error_redirect(&query, "invalid_request", "openid scope missing!");
|
return error_redirect(&query, "invalid_request", "openid scope missing!");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user