Skip to content

Commit

Permalink
chore(ui): Make Clippy happy.
Browse files Browse the repository at this point in the history
  • Loading branch information
Hywan committed Dec 18, 2024
1 parent 880e05c commit 888082e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/matrix-sdk-ui/src/timeline/controller/state.rs
Original file line number Diff line number Diff line change
Expand Up @@ -798,7 +798,7 @@ impl TimelineStateTransaction<'_> {
let mut idx = 0;
while idx < self.items.len() {
if self.items[idx].is_date_divider()
&& self.items.get(idx + 1).map_or(true, |item| item.is_date_divider())
&& self.items.get(idx + 1).is_none_or(|item| item.is_date_divider())
{
self.items.remove(idx);
// don't increment idx because all elements have shifted
Expand Down

0 comments on commit 888082e

Please sign in to comment.