fix all the warnings!!!! (0 clippy and rustc warnings now)
too many changes to list, codebase significantly better than it was a few weeks ago though Signed-off-by: strawberry <june@girlboss.ceo>
This commit is contained in:
parent
20b686cac5
commit
87d6a17f0a
27 changed files with 162 additions and 139 deletions
|
@ -50,8 +50,10 @@ pub async fn create_content_route(
|
|||
)
|
||||
.await?;
|
||||
|
||||
let content_uri = mxc.into();
|
||||
|
||||
Ok(create_content::v3::Response {
|
||||
content_uri: mxc.try_into()?,
|
||||
content_uri,
|
||||
blurhash: None,
|
||||
})
|
||||
}
|
||||
|
|
|
@ -722,7 +722,8 @@ async fn join_room_by_id_helper(
|
|||
}
|
||||
|
||||
info!("Running send_join auth check");
|
||||
if !state_res::event_auth::auth_check(
|
||||
|
||||
let auth_check = state_res::event_auth::auth_check(
|
||||
&state_res::RoomVersion::new(&room_version_id).expect("room version is supported"),
|
||||
&parsed_join_pdu,
|
||||
None::<PduEvent>, // TODO: third party invite
|
||||
|
@ -745,7 +746,9 @@ async fn join_room_by_id_helper(
|
|||
.map_err(|e| {
|
||||
warn!("Auth check failed: {e}");
|
||||
Error::BadRequest(ErrorKind::InvalidParam, "Auth check failed")
|
||||
})? {
|
||||
})?;
|
||||
|
||||
if !auth_check {
|
||||
return Err(Error::BadRequest(
|
||||
ErrorKind::InvalidParam,
|
||||
"Auth check failed",
|
||||
|
|
|
@ -572,7 +572,7 @@ pub async fn get_server_version_route(
|
|||
|
||||
Ok(get_server_version::v1::Response {
|
||||
server: Some(get_server_version::v1::Server {
|
||||
name: Some("cowonduit".to_owned()),
|
||||
name: Some(env!("CARGO_CRATE_NAME").to_owned()),
|
||||
version: Some(env!("CARGO_PKG_VERSION").to_owned()),
|
||||
}),
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue