From 5586eeaba885f362d17b03f507154484a8531e90 Mon Sep 17 00:00:00 2001 From: Maximiliano Sandoval Date: Mon, 26 Aug 2024 14:15:29 +0200 Subject: [PATCH] rrd_map: remove unneded return statement Fixes: warning: unneeded `return` statement --> proxmox-rrd/src/cache/rrd_map.rs:117:13 | 117 | return Ok(true); | ^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return = note: `#[warn(clippy::needless_return)]` on by default help: remove `return` | 117 - return Ok(true); 117 + Ok(true) | warning: unneeded `return` statement --> proxmox-rrd/src/cache/rrd_map.rs:119:13 | 119 | return Ok(false); | ^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return help: remove `return` | 119 - return Ok(false); 119 + Ok(false) Signed-off-by: Maximiliano Sandoval --- proxmox-rrd/src/cache/rrd_map.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/proxmox-rrd/src/cache/rrd_map.rs b/proxmox-rrd/src/cache/rrd_map.rs index fa9eaa1f..7fe19ccb 100644 --- a/proxmox-rrd/src/cache/rrd_map.rs +++ b/proxmox-rrd/src/cache/rrd_map.rs @@ -114,9 +114,9 @@ impl RRDMap { if let Some(rrd) = (self.load_rrd_cb)(&path, rel_path) { self.map.insert(rel_path.to_string(), rrd); - return Ok(true); + Ok(true) } else { - return Ok(false); + Ok(false) } } }