From a527f7396e37d22bff4eb2469c0670c2e2823bf9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrian=20Wo=C5=BAniak?= Date: Mon, 2 Aug 2021 10:21:11 +0200 Subject: [PATCH] Replace len() < 1 with is_empty() --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 6c1f2e3..f882c0e 100644 --- a/src/main.rs +++ b/src/main.rs @@ -145,7 +145,7 @@ fn controllers(config: &Config, filter: bool) -> std::io::Result> { fn service(config: Config) -> std::io::Result<()> { let mut controllers = controllers(&config, true)?; - if controllers.len() < 1 { + if controllers.is_empty() { return Err(not_found()); } let mut cache = std::collections::HashMap::new();