From 0a71385b29d994a1291053071024fa003b9c1694 Mon Sep 17 00:00:00 2001 From: Pierre Dubouilh Date: Wed, 6 Apr 2022 08:54:11 +0200 Subject: [PATCH] fix clippy --- src/unit.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/unit.rs b/src/unit.rs index f2d36cd..4b327bc 100644 --- a/src/unit.rs +++ b/src/unit.rs @@ -349,9 +349,8 @@ fn connect_socket(unit: &Unit, hostname: &str, use_pooled: bool) -> Result<(Stre scheme => return Err(ErrorKind::UnknownScheme.msg(format!("unknown scheme '{}'", scheme))), }; if unit.url.scheme() != "https" && unit.agent.config.https_only { - return Err(ErrorKind::InsecureRequestHttpsOnly.msg(format!( - "can't perform non https request with https_only set" - ))); + return Err(ErrorKind::InsecureRequestHttpsOnly + .msg("can't perform non https request with https_only set")); } if use_pooled { let pool = &unit.agent.state.pool;