From 8ccc8f126ab93f783f3be1b78b971e7c8c8a3a12 Mon Sep 17 00:00:00 2001 From: monosans Date: Wed, 28 May 2025 16:41:52 +0300 Subject: [PATCH] remove useless wrap_err --- src/parsers.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/parsers.rs b/src/parsers.rs index 37d2ae9..ade9160 100644 --- a/src/parsers.rs +++ b/src/parsers.rs @@ -20,9 +20,7 @@ static IPV4_REGEX: LazyLock = LazyLock::new(|| { }); pub fn parse_ipv4(s: &str) -> Option { - if let Ok(Some(captures)) = - IPV4_REGEX.captures(s).wrap_err("failed to match regex capture groups") - { + if let Ok(Some(captures)) = IPV4_REGEX.captures(s) { captures.name("host").map(|capture| capture.as_str().to_owned()) } else { None