Skip to content

Commit 36f4892

Browse files
Fix clippy warnings
1 parent 801f006 commit 36f4892

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

gtk4/src/list_store.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ impl ListStore {
100100
"Incorrect `new_order` slice length. Expected `{count}`, found `{}`.",
101101
new_order.len()
102102
);
103-
let safe_values = new_order.iter().max().map_or(true, |&max| {
103+
let safe_values = new_order.iter().max().is_none_or(|&max| {
104104
let max = max as i32;
105105
max >= 0 && max < count
106106
});

gtk4/src/tree_store.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ impl TreeStore {
102102
"Incorrect `new_order` slice length. Expected `{count}`, found `{}`.",
103103
new_order.len()
104104
);
105-
let safe_values = new_order.iter().max().map_or(true, |&max| {
105+
let safe_values = new_order.iter().max().is_none_or(|&max| {
106106
let max = max as i32;
107107
max >= 0 && max < count
108108
});

0 commit comments

Comments
 (0)