We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2bb0633 commit 3f5fc2eCopy full SHA for 3f5fc2e
crates/url/src/decode.rs
@@ -7,7 +7,7 @@ use alloc::{
7
use crate::Result;
8
9
/// UrlDecode the given string
10
-pub fn decode(url: &str) -> Result<Cow<str>> {
+pub fn decode(url: &str) -> Result<Cow<'_, str>> {
11
if !url.contains(['%', '+']) {
12
return Ok(url.into());
13
}
crates/url/src/encode.rs
@@ -3,7 +3,7 @@ use alloc::{borrow::Cow, string::String};
3
4
5
/// UrlEncode the given string
6
-pub fn encode(url: &str) -> Result<Cow<str>> {
+pub fn encode(url: &str) -> Result<Cow<'_, str>> {
let is_ascii = |c: &u8| {
matches!(c, b'0'..=b'9' | b'A'..=b'Z'
| b'a'..=b'z' | b'-' | b'.'
0 commit comments