From 5c253468a59eed17a04ed9eed23da90f1b1da1a8 Mon Sep 17 00:00:00 2001 From: Kostya Shishkov Date: Sat, 20 May 2017 17:48:20 +0200 Subject: [PATCH] simplify --- src/codecs/mod.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/codecs/mod.rs b/src/codecs/mod.rs index 75f07c1..14cb0b3 100644 --- a/src/codecs/mod.rs +++ b/src/codecs/mod.rs @@ -53,12 +53,13 @@ impl HAMShuffler { } #[allow(dead_code)] fn clone_ref(&mut self) -> Option { - if let None = self.lastframe { return None; } if let Some(ref mut frm) = self.lastframe { let newfrm = Rc::new(RefCell::new(NAFrame::from_copy(&frm.borrow()))); *frm = newfrm.clone(); Some(newfrm) - } else { None } + } else { + None + } } #[allow(dead_code)] fn get_output_frame(&mut self) -> Option { -- 2.39.5