From cbe39f008eba6df4a71b2dfe1401c1970ced7d8c Mon Sep 17 00:00:00 2001 From: Keivan-sf Date: Sun, 27 Jul 2025 20:32:12 +0330 Subject: [PATCH] Add missing url_decode_str function --- src/utils/mod.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/utils/mod.rs b/src/utils/mod.rs index e40bd46..54a8d93 100644 --- a/src/utils/mod.rs +++ b/src/utils/mod.rs @@ -1,5 +1,11 @@ pub mod inbound_generator; +pub fn url_decode_str(value: &str) -> Option { + return urlencoding::decode(value) + .ok() + .map(|decoded| decoded.into_owned()); +} + pub fn url_decode(value: Option) -> Option { return value.and_then(|s| { urlencoding::decode(&s)