From: Kostya Shishkov Date: Sat, 20 May 2017 15:48:20 +0000 (+0200) Subject: simplify X-Git-Url: https://git.nihav.org/?a=commitdiff_plain;h=5c253468a59eed17a04ed9eed23da90f1b1da1a8;p=nihav.git simplify --- 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 {