style: cargo clippy & cargo fmt
This commit is contained in:
parent
19f64d413c
commit
e59f7b5a1f
20 changed files with 137 additions and 67 deletions
|
@ -28,7 +28,7 @@ pub async fn get(
|
|||
|
||||
Member::check_membership(&mut conn, uuid, guild_uuid).await?;
|
||||
|
||||
if let Ok(cache_hit) = data.get_cache_key(format!("{}", role_uuid)).await {
|
||||
if let Ok(cache_hit) = data.get_cache_key(format!("{role_uuid}")).await {
|
||||
return Ok(HttpResponse::Ok()
|
||||
.content_type("application/json")
|
||||
.body(cache_hit));
|
||||
|
@ -36,7 +36,7 @@ pub async fn get(
|
|||
|
||||
let role = Role::fetch_one(&mut conn, role_uuid).await?;
|
||||
|
||||
data.set_cache_key(format!("{}", role_uuid), role.clone(), 60)
|
||||
data.set_cache_key(format!("{role_uuid}"), role.clone(), 60)
|
||||
.await?;
|
||||
|
||||
Ok(HttpResponse::Ok().json(role))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue