mirror of
https://forgejo.ellis.link/continuwuation/continuwuity/
synced 2026-10-07 19:27:18 +00:00
chore: Clippy fixes
This commit is contained in:
@@ -68,8 +68,7 @@ pub(crate) async fn update_device_route(
|
||||
|
||||
services
|
||||
.users
|
||||
.update_device_metadata(sender_user, &body.device_id, &device)
|
||||
.await?;
|
||||
.update_device_metadata(sender_user, &body.device_id, &device)?;
|
||||
|
||||
Ok(update_device::v3::Response::new())
|
||||
},
|
||||
|
||||
@@ -104,12 +104,15 @@ impl<S> FromRequestParts<S> for ClientIp
|
||||
{
|
||||
type Rejection = ClientIpError;
|
||||
|
||||
async fn from_request_parts(parts: &mut Parts, state: &S) -> Result<Self, Self::Rejection> {
|
||||
Self::for_config(
|
||||
fn from_request_parts(
|
||||
parts: &mut Parts,
|
||||
state: &S,
|
||||
) -> impl Future<Output = Result<Self, Self::Rejection>> {
|
||||
std::future::ready(Self::for_config(
|
||||
parts,
|
||||
&state.config.accepted_ip_sources,
|
||||
state.config.request_ip_source.as_ref(),
|
||||
)
|
||||
))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -331,14 +331,14 @@ async fn verify<B: AsRef<[u8]> + Sync>(
|
||||
impl CheckAuth for NoAuthentication {
|
||||
type Identity = ();
|
||||
|
||||
async fn verify<B: AsRef<[u8]> + Sync>(
|
||||
fn verify<B: AsRef<[u8]> + Sync>(
|
||||
_services: &Services,
|
||||
_output: Self::Output,
|
||||
_request: &hyper::Request<B>,
|
||||
_query: AuthQueryParams,
|
||||
_route: TypeId,
|
||||
) -> Result<Self::Identity> {
|
||||
Ok(())
|
||||
) -> impl Future<Output = Result<Self::Identity>> {
|
||||
std::future::ready(Ok(()))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user