mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-20 20:36:08 +08:00
Apply clippy lints (#278)
This commit is contained in:
committed by
Keavon Chambers
parent
0c25031ad1
commit
5b1d36fafe
@@ -105,9 +105,7 @@ impl Folder {
|
||||
pub fn bounding_box(&self, transform: glam::DAffine2) -> Option<[DVec2; 2]> {
|
||||
let mut layers_non_empty_bounding_boxes = self.layers.iter().filter_map(|layer| layer.bounding_box(transform * layer.transform, layer.style)).peekable();
|
||||
|
||||
if layers_non_empty_bounding_boxes.peek().is_none() {
|
||||
return None;
|
||||
}
|
||||
layers_non_empty_bounding_boxes.peek()?;
|
||||
|
||||
let mut x_min = f64::MAX;
|
||||
let mut y_min = f64::MAX;
|
||||
@@ -128,7 +126,7 @@ impl Folder {
|
||||
y_max = bounding_box_max.y
|
||||
}
|
||||
}
|
||||
return Some([DVec2::new(x_min, y_min), DVec2::new(x_max, y_max)]);
|
||||
Some([DVec2::new(x_min, y_min), DVec2::new(x_max, y_max)])
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user