Author: Manos Pitsidianakis [manos@pitsidianak.is]
Hash: 19e8b626caca641ea09b3847c2045ad515e005c9
Timestamp: Sun, 29 Oct 2023 10:39:54 +0000 (10 months ago)

+2 -2 +/-2 browse
web: fix clippy lints
web: fix clippy lints

Signed-off-by: Manos Pitsidianakis <manos@pitsidianak.is>
1diff --git a/web/src/lists.rs b/web/src/lists.rs
2index fa2047a..e9c2009 100644
3--- a/web/src/lists.rs
4+++ b/web/src/lists.rs
5 @@ -68,7 +68,7 @@ pub async fn list(
6 let mut threads: melib::Threads = melib::Threads::new(posts.len());
7 drop(env_lock);
8 threads.amend(&envelopes);
9- let roots = thread_roots(&envelopes, &mut threads);
10+ let roots = thread_roots(&envelopes, &threads);
11 let posts_ctx = roots
12 .into_iter()
13 .map(|(thread, length, _timestamp)| {
14 diff --git a/web/src/utils.rs b/web/src/utils.rs
15index 03f25ac..8321ec1 100644
16--- a/web/src/utils.rs
17+++ b/web/src/utils.rs
18 @@ -440,7 +440,7 @@ pub fn thread(
19
20 pub fn thread_roots(
21 envelopes: &Arc<std::sync::RwLock<HashMap<melib::EnvelopeHash, melib::Envelope>>>,
22- threads: &mut melib::Threads,
23+ threads: &melib::Threads,
24 ) -> Vec<(ThreadEntry, usize, u64)> {
25 let items = threads.roots();
26 let env_lock = envelopes.read().unwrap();