From e8c7df4593b5cc05eef55572e001b48eeefd9466 Mon Sep 17 00:00:00 2001 From: Matthias Beyer Date: Sat, 5 Dec 2015 11:03:05 +0100 Subject: [PATCH] Remove variable, use expression directly --- src/module/bm/commands.rs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/module/bm/commands.rs b/src/module/bm/commands.rs index 03952ce2..ad8f358f 100644 --- a/src/module/bm/commands.rs +++ b/src/module/bm/commands.rs @@ -88,10 +88,8 @@ pub fn remove_command(module: &Module, env: CommandEnv) -> CommandResult { }) .collect::>(); - let nerrs = errs.len(); - - if nerrs != 0 { - warn!("{} Errors occured while removing {} files", nerrs, nfiles); + if errs.len() != 0 { + warn!("{} Errors occured while removing {} files", errs.len(), nfiles); let moderr = ModuleError::new("File removal failed"); // TODO : Collect StorageBackendErrors