From 692b0804481adc1a6356c1bc980a3e81313ef1ef Mon Sep 17 00:00:00 2001 From: Bruce Mitchener Date: Mon, 16 Dec 2024 00:07:56 -0500 Subject: [PATCH] Fix `clippy::question_mark` lint (#794) --- masonry/src/widget/grid.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/masonry/src/widget/grid.rs b/masonry/src/widget/grid.rs index 261e184b5..a752aca9c 100644 --- a/masonry/src/widget/grid.rs +++ b/masonry/src/widget/grid.rs @@ -215,11 +215,7 @@ impl Grid { this: &'t mut WidgetMut<'_, Self>, idx: usize, ) -> Option>> { - let child = match this.widget.children[idx].widget_mut() { - Some(widget) => widget, - None => return None, - }; - + let child = this.widget.children[idx].widget_mut()?; Some(this.ctx.get_mut(child)) }