aboutsummaryrefslogtreecommitdiff
path: root/server/src/routes/ui
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2025-02-07 16:21:41 +0100
committermetamuffin <metamuffin@disroot.org>2025-02-07 16:21:41 +0100
commit9ff2358adca561b7723e9c4d79efce87025d2e4e (patch)
treee5f4f2e35df718dd9bc65623cc625f7ac11c2811 /server/src/routes/ui
parent0bba75241d59c64375cfece494eb9dcdbaa664fc (diff)
downloadjellything-9ff2358adca561b7723e9c4d79efce87025d2e4e.tar
jellything-9ff2358adca561b7723e9c4d79efce87025d2e4e.tar.bz2
jellything-9ff2358adca561b7723e9c4d79efce87025d2e4e.tar.zst
clippy
Diffstat (limited to 'server/src/routes/ui')
-rw-r--r--server/src/routes/ui/admin/mod.rs4
-rw-r--r--server/src/routes/ui/mod.rs2
-rw-r--r--server/src/routes/ui/player.rs6
3 files changed, 6 insertions, 6 deletions
diff --git a/server/src/routes/ui/admin/mod.rs b/server/src/routes/ui/admin/mod.rs
index 10c7365..15cc5c0 100644
--- a/server/src/routes/ui/admin/mod.rs
+++ b/server/src/routes/ui/admin/mod.rs
@@ -171,10 +171,10 @@ pub async fn r_admin_update_search(
.await
.unwrap();
admin_dashboard(
- &database,
+ database,
Some(
r.map_err(|e| e.into())
- .map(|_| format!("Search index updated")),
+ .map(|_| "Search index updated".to_string()),
),
)
.await
diff --git a/server/src/routes/ui/mod.rs b/server/src/routes/ui/mod.rs
index bffdfdd..9a3e61b 100644
--- a/server/src/routes/ui/mod.rs
+++ b/server/src/routes/ui/mod.rs
@@ -68,7 +68,7 @@ impl<'r> Responder<'r, 'static> for HtmlTemplate<'_> {
self.0.render(&mut out).unwrap();
Response::build()
.header(ContentType::HTML)
- .sized_body(out.as_bytes().len(), Cursor::new(out))
+ .sized_body(out.len(), Cursor::new(out))
.ok()
}
}
diff --git a/server/src/routes/ui/player.rs b/server/src/routes/ui/player.rs
index f680a45..2f28f74 100644
--- a/server/src/routes/ui/player.rs
+++ b/server/src/routes/ui/player.rs
@@ -58,12 +58,12 @@ fn jellynative_url(action: &str, seek: f64, secret: &str, node: &str, session: &
}
#[get("/n/<id>/player?<conf..>", rank = 4)]
-pub fn r_player<'a>(
+pub fn r_player(
sess: Session,
- db: &'a State<Database>,
+ db: &State<Database>,
id: NodeID,
conf: PlayerConfig,
-) -> MyResult<Either<DynLayoutPage<'a>, Redirect>> {
+) -> MyResult<Either<DynLayoutPage<'_>, Redirect>> {
let node = db.get_node(id)?.ok_or(anyhow!("node does not exist"))?;
let native_session = |action: &str| {