From 69a77b36172503ada9047a756bb5972a4c7005dc Mon Sep 17 00:00:00 2001 From: metamuffin Date: Wed, 19 Mar 2025 19:35:16 +0100 Subject: clippy --- src/modules/auth/openid.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/modules/auth/openid.rs') diff --git a/src/modules/auth/openid.rs b/src/modules/auth/openid.rs index db03c2f..e22bc24 100644 --- a/src/modules/auth/openid.rs +++ b/src/modules/auth/openid.rs @@ -143,7 +143,7 @@ id_token={id_token:?}"# let mut v = context .state .crypto_key - .encrypt(Nonce::from_slice(&nonce), Payload { msg: &r, aad: &[] }) + .encrypt(Nonce::from_slice(&nonce), Payload { msg: r, aad: &[] }) .unwrap(); v.extend(nonce); @@ -190,7 +190,7 @@ fn redirect_uri(request: &NodeRequest) -> Result { .to_str()?, ) .ok(); - Ok(Uri::from_parts(redirect_uri).map_err(|_| ServiceError::InvalidUri)?) + Uri::from_parts(redirect_uri).map_err(|_| ServiceError::InvalidUri) } async fn token_request( @@ -234,8 +234,8 @@ async fn token_request( let mut buf = String::new(); body.reader().read_to_string(&mut buf).unwrap(); eprintln!("{buf}"); - Ok(serde_json::from_str(&buf) - .map_err(|_| ServiceError::CustomStatic("invalid token response"))?) + serde_json::from_str(&buf) + .map_err(|_| ServiceError::CustomStatic("invalid token response")) } #[derive(Debug, Deserialize)] -- cgit v1.2.3-70-g09d2