Day 11 fix clippy lint

This commit is contained in:
Aadi Desai 2023-12-12 18:03:50 +00:00
parent 79ab2f9787
commit fd0413d1ae
Signed by: supleed2
SSH key fingerprint: SHA256:CkbNRs0yVzXEiUp2zd0PSxsfRUMFF9bLlKXtE1xEbKM

View file

@ -18,7 +18,7 @@ async fn red_pixels(mut multipart: Multipart) -> impl IntoResponse {
.expect("Loading image should not fail")
.into_rgb8()
.pixels()
.filter(|&p| p.0[0] as u16 > p.0[1] as u16 + p.0[2] as u16)
.filter(|&p| u16::from(p.0[0]) > u16::from(p.0[1]) + u16::from(p.0[2]))
.count()
.to_string()
} else {