Skip to content

Commit

Permalink
Appease clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
madsmtm committed Jan 28, 2025
1 parent 00a1a21 commit d385630
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/drm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ mod imple {
let planes = planes
.iter()
.filter(|&&plane| {
device.get_plane(plane).map_or(false, |plane| {
device.get_plane(plane).is_ok_and(|plane| {
let crtcs = handles.filter_crtcs(plane.possible_crtcs());
crtcs.contains(&crtc.handle())
})
Expand All @@ -77,7 +77,7 @@ mod imple {
let (ids, vals) = props.as_props_and_values();
for (&id, &val) in ids.iter().zip(vals.iter()) {
if let Ok(info) = device.get_property(id) {
if info.name().to_str().map_or(false, |x| x == "type") {
if info.name().to_str() == Ok("type") {
return val == PlaneType::Primary as u32 as u64;
}
}
Expand Down

0 comments on commit d385630

Please sign in to comment.